Compare commits
1466 Commits
Author | SHA1 | Date |
---|---|---|
|
8570d26ed2 | |
|
49d0a8acf8 | |
![]() |
e395c8ec6b | |
|
824281e04a | |
|
cce56aa486 | |
|
c224680e88 | |
|
926a29534b | |
|
d7fdf20aaf | |
|
c5023912db | |
|
79b3d3c8b0 | |
|
ea8aae4ebb | |
|
493275376f | |
![]() |
e85e366b7e | |
|
e7301c6fd7 | |
|
fd162ecffd | |
|
91b8d6f2bb | |
|
53103af8b7 | |
|
0adee1e8f7 | |
|
3cf15d2784 | |
|
f68de2e7fe | |
|
2fba207cd8 | |
|
b8706fa58c | |
|
413fb01573 | |
|
ce2075bb6f | |
|
9fe50205bd | |
|
f0c5367350 | |
![]() |
e94d0fc933 | |
![]() |
ef5ab4ad8a | |
|
159a5eff12 | |
|
f451e0ca13 | |
![]() |
d9336d946e | |
![]() |
8b3558d025 | |
![]() |
b3049a3440 | |
|
142f0292d5 | |
|
c3d6388401 | |
![]() |
d7e9a2c396 | |
![]() |
4a79cb6f66 | |
![]() |
c958247583 | |
|
cd00552da7 | |
|
34ba528c42 | |
![]() |
5eefefcf54 | |
|
627dfdeb75 | |
![]() |
1f97bae34e | |
|
d3a40e953a | |
|
eb1472c873 | |
|
510bc0e5b9 | |
|
9b65b907f9 | |
|
284f7062ce | |
|
16cbd14035 | |
|
3d545c6229 | |
|
feeaa3c61e | |
|
5a6b667657 | |
|
164a84aac9 | |
|
8e02f87e96 | |
|
9bda063973 | |
![]() |
8732258bd1 | |
|
47f70368a5 | |
|
f96fa20af7 | |
|
4247204616 | |
|
8a8eb2de4b | |
|
b0dde744e5 | |
|
d35f9aba87 | |
![]() |
ed59ccc27d | |
|
98fb807ca4 | |
![]() |
9a87f5ab8b | |
|
6311b5fe27 | |
|
55cff09ad1 | |
|
ab0e3653a9 | |
|
3d91a8aa9e | |
|
d55b6d4ed4 | |
|
26835aad53 | |
|
92e03b1841 | |
|
1920dd45ff | |
|
818d2e172d | |
|
58acb3cb24 | |
|
0976c31aaa | |
|
6257bac47c | |
|
cb1f6735eb | |
|
85a15789b7 | |
|
6e0c575e80 | |
|
a4eb392603 | |
|
cae5c75601 | |
|
db38d2400f | |
![]() |
ffaff224a1 | |
![]() |
43b4000061 | |
![]() |
2c8c0f0355 | |
![]() |
00f3bdd2fa | |
|
56c3e65592 | |
|
7c80af263d | |
![]() |
14a641a6a7 | |
|
1a225378db | |
|
ca68cafd8e | |
|
2d2349b823 | |
|
0ccce93dcb | |
|
33af09ae5d | |
![]() |
c65174a29c | |
![]() |
fee83215d3 | |
|
a028015ef9 | |
![]() |
7fa9f8b435 | |
|
d707fc0316 | |
|
06583dd486 | |
|
d1a8989f57 | |
|
8dc96fef51 | |
![]() |
1df34f59d2 | |
![]() |
3e92646443 | |
|
5e3733a842 | |
|
65e4629b17 | |
|
d686026d83 | |
|
e6780ed7bc | |
|
d33c6f1842 | |
![]() |
f5fb861684 | |
|
11ee2ed128 | |
|
a40147fb44 | |
![]() |
2d575f7626 | |
|
dde3a4031b | |
|
1b004638d1 | |
|
283038ddfc | |
|
3384ada324 | |
![]() |
c98117ac59 | |
|
b455f24c31 | |
|
2eb21659ee | |
|
a9b4f37ed4 | |
|
b2042b63b8 | |
![]() |
2b2e3fe843 | |
|
672e9144a5 | |
|
351c172dea | |
|
e9377814c0 | |
![]() |
ba86472516 | |
|
6805d9fa35 | |
![]() |
ec3eb0cd92 | |
|
db6b000caf | |
|
52cc7698f9 | |
![]() |
7a4b25940c | |
|
9084201713 | |
![]() |
bcae5caf76 | |
|
23202b67ce | |
|
0898600474 | |
|
686295cd14 | |
|
d5f0ed77f8 | |
![]() |
e7e0d3bf0e | |
![]() |
fac072b40a | |
|
381aa7d3a5 | |
|
c6619eab29 | |
![]() |
e7e0a86c94 | |
|
7ebaca5e4f | |
![]() |
d8c2ab66b4 | |
|
28bc05375e | |
|
c19cd0f83f | |
|
651f137fce | |
|
40ac8b719f | |
|
ce8bc49cf0 | |
![]() |
fb2287246a | |
|
f28de89690 | |
|
3c50bf6622 | |
|
2e42d61e58 | |
![]() |
fd19250c73 | |
|
6eda288038 | |
![]() |
3f6b540d8b | |
|
5a3993bb29 | |
|
f0516e628d | |
|
2006d94e68 | |
|
449295874a | |
|
8b19d2dcb8 | |
|
fb5660754c | |
|
c54ee626df | |
|
c844924e26 | |
|
1d3022c2c2 | |
![]() |
ca4087cec3 | |
|
b30ca531f8 | |
![]() |
03107a4960 | |
|
909bcc0564 | |
|
d1f9eacbf7 | |
|
f4bffadf78 | |
|
cfaae2eb22 | |
|
6429208609 | |
|
c4e1b7d63a | |
|
e4bf3b465a | |
|
74cf711096 | |
|
a730cf0ff4 | |
![]() |
45494d9abe | |
|
edb7fc5a71 | |
|
f0c04daef7 | |
|
f98bf15eb9 | |
|
267af8792d | |
|
9e3986d455 | |
![]() |
11399a873f | |
![]() |
4620f952d3 | |
|
370a10a91a | |
|
1dd7553c02 | |
|
d0cbc92941 | |
|
02ce1781d3 | |
|
c6ea41fa7b | |
|
da00c6d212 | |
|
0fbfa0e41c | |
|
395f7bf384 | |
|
00030d7d91 | |
|
cf28f035d2 | |
|
b131003058 | |
|
57cf8e196b | |
![]() |
a2185290b5 | |
|
41ffa7a1f5 | |
![]() |
d33020f1a3 | |
|
0b63a1f06e | |
|
c12977d4fd | |
![]() |
d80d351ebc | |
|
c405880d62 | |
|
bf3c094de8 | |
|
44a7104bd4 | |
![]() |
927a1df285 | |
![]() |
6cb5e3238c | |
|
e007ab2c8a | |
|
3943253b8e | |
|
4a2bcdc817 | |
![]() |
874baba10a | |
|
43ee4bd48b | |
|
6e7b79dad6 | |
|
e6e4a64f6f | |
![]() |
b2aa9e39eb | |
|
ba5a7a4cf1 | |
|
1b4ee6646a | |
![]() |
7f297125bc | |
|
c7697bd24a | |
|
5b3f650d4a | |
|
fbedf2b274 | |
|
4ea5611b25 | |
![]() |
820c47f7cc | |
![]() |
315ff4e8f8 | |
|
8fdb3aeda7 | |
|
23e4105aef | |
|
d23e5af60f | |
![]() |
79798d387a | |
|
68f756efe2 | |
|
6e990c4468 | |
|
f81129a978 | |
|
79aa8ebe1a | |
![]() |
055ecb55d0 | |
![]() |
32a0c28615 | |
![]() |
ada12a3210 | |
![]() |
8d75e9e313 | |
|
7b72f05fa6 | |
|
4263322c6a | |
|
35c7105a30 | |
|
7b40394d64 | |
![]() |
542d251691 | |
|
164aec16bf | |
|
05c1734b60 | |
|
df73a466d6 | |
![]() |
7f08819e43 | |
|
38f952a241 | |
![]() |
4304a77812 | |
|
d30feaa65d | |
|
dc65a77c17 | |
|
0d82d753c8 | |
|
9278a8b132 | |
|
aa06ac0101 | |
![]() |
0428b8a051 | |
![]() |
fafd78ec0e | |
|
fcbd8510db | |
![]() |
507164cb96 | |
|
b899f1441c | |
|
1ce7373f36 | |
|
9f5f522507 | |
|
735e8b277c | |
|
90fd718287 | |
|
7ade83926d | |
|
1f62b2bdae | |
|
104f0f9f72 | |
|
8b83664b1d | |
|
cea63fae84 | |
![]() |
04e8f987cd | |
|
67e202713f | |
|
6a79e8d76e | |
|
512985cc5c | |
|
28bc43ac6f | |
|
30adb608c7 | |
|
2bab5f6873 | |
![]() |
80147ff0d3 | |
![]() |
f14076954e | |
![]() |
d7345988d8 | |
|
5b4626a277 | |
|
d4d1bf7cf5 | |
|
8eadb8c886 | |
|
2f9e11f8f3 | |
![]() |
d2204c2179 | |
![]() |
0114b207ac | |
![]() |
40404a4e27 | |
|
be0facf3cf | |
![]() |
4db92bab41 | |
![]() |
482bea7841 | |
|
d21ee89c59 | |
|
2a77abfb91 | |
|
57c1372c4a | |
![]() |
748192d77c | |
![]() |
46d7b16adf | |
|
c42598c152 | |
|
4c0d70933a | |
![]() |
2a9ccc868e | |
|
5a6dd07d88 | |
|
fa54b35d0e | |
|
57337cf2a2 | |
|
1fde069a2b | |
![]() |
11c946c774 | |
|
f5ad126ab5 | |
|
a450b744e3 | |
![]() |
4b3204f6a1 | |
|
f78d128f16 | |
![]() |
10e3dc53de | |
|
00bc60a439 | |
|
ff45fac27e | |
|
9d7297c805 | |
|
e1e7aae610 | |
![]() |
8f06c377d8 | |
|
afc602d1cf | |
|
4b028497d5 | |
|
520b6950d6 | |
![]() |
474ede8eea | |
![]() |
422423bc55 | |
|
9bd0036f13 | |
|
9e7c5b7d58 | |
|
9eae8bc8c4 | |
|
b383e925df | |
|
078044bd93 | |
![]() |
dfedd7e27c | |
|
9d73cff60d | |
|
6b0a66d711 | |
|
43b449d280 | |
|
4fd38a6fdb | |
![]() |
5b32fb6df2 | |
![]() |
1c150c549b | |
|
46d371da92 | |
|
847a026784 | |
|
5521cfd23f | |
|
73f060a0e3 | |
![]() |
4698253785 | |
|
7d2de9240e | |
|
42b895aa9c | |
![]() |
a8222fd589 | |
|
61352ae7ec | |
|
4b4b6b03d7 | |
|
3129e82bd0 | |
![]() |
1e40f9fec2 | |
|
eef1fa2d17 | |
|
167724ef3a | |
|
3e8eaf7bc1 | |
|
3233b7af5f | |
|
e7788ba1b5 | |
|
9b1f4f78d0 | |
|
ab6bdf41d7 | |
|
0da5a00e89 | |
![]() |
f0532c3de8 | |
|
0a8cbe7d50 | |
|
62680bf46d | |
|
6d8c8b778a | |
|
ea00a45287 | |
|
a32b19be56 | |
|
1d04c8f8f6 | |
![]() |
4232d42dbc | |
![]() |
1f4ece0d82 | |
![]() |
1e39660a5b | |
|
e84b4e7d35 | |
|
6565c348a3 | |
![]() |
5dbed34ade | |
|
2f7058437e | |
|
53dac5dd18 | |
![]() |
05714a4da1 | |
|
e610177440 | |
|
209a0ce304 | |
|
daa9957185 | |
![]() |
43479a3929 | |
|
75d7536e1a | |
|
05043cfa83 | |
![]() |
6d0baa43ff | |
|
47a3cff12c | |
|
eb908008ac | |
|
9d391fb1a2 | |
|
d542022a88 | |
|
2914ca0b7f | |
|
167cd0852e | |
|
9f00fd08a5 | |
![]() |
f35af2c7ab | |
![]() |
b1915d7333 | |
|
802d0bea6b | |
|
52d7536dfb | |
|
f000c021c3 | |
|
98a55f001c | |
|
c9e84bf806 | |
|
f9a0131bea | |
|
94642f6160 | |
|
636ef1483e | |
|
12bfcf20fc | |
![]() |
a54fb145d4 | |
|
27fe71bc6c | |
|
ef74a75ba6 | |
|
a744c98729 | |
|
2f4c6a70b3 | |
|
a5a8b8d9de | |
|
fabed704e8 | |
![]() |
b3ac31aa4a | |
|
c93a1a587b | |
|
fbf455a895 | |
|
535b3f636e | |
|
2dbfdd0ceb | |
![]() |
5387daeb20 | |
|
55144b7ddc | |
|
f17cf39df0 | |
|
0346b46533 | |
|
92b2167193 | |
|
58159a36a5 | |
|
5dd07b68d3 | |
|
a0fe3c28f7 | |
![]() |
ff01fc83dd | |
|
f6f02c3ead | |
|
33dcd072d9 | |
![]() |
844781c2fd | |
|
7df81133bc | |
|
f579a87704 | |
|
bce8108587 | |
|
b84fdb60e4 | |
|
52ba30c587 | |
|
0fa3d34df0 | |
|
3f4a8b287c | |
|
35defea078 | |
![]() |
f7728cdd4e | |
|
916b812580 | |
![]() |
8bcca660e7 | |
|
094a2682b8 | |
|
8bf4bef2f6 | |
![]() |
8a81cb2b0e | |
|
9254b593ec | |
|
dfc53bcb8a | |
|
0617f73b68 | |
|
3b8d348f88 | |
|
3d9d5f0238 | |
|
731fa013b3 | |
|
5b4502a1a8 | |
|
fb54b30184 | |
|
43bccffe8c | |
|
4069894bb4 | |
|
7bab069a3e | |
|
3fa423046e | |
|
db9e42be88 | |
|
c6511661fa | |
|
e6022eddc8 | |
|
34b7b9c87e | |
|
0a70e20501 | |
|
6a9ce63743 | |
|
cd68f09dea | |
|
abae09d41a | |
![]() |
2b319877d4 | |
|
9970a5d8ae | |
![]() |
e1f0165059 | |
|
4935fb2dd6 | |
|
ad895b4a37 | |
![]() |
41275ff32e | |
|
ce6f99fbd9 | |
|
f232687df1 | |
|
d6f3ece419 | |
![]() |
d4357485f8 | |
|
1ed039aa6f | |
|
21db207dcd | |
|
ff67c3c137 | |
|
6aa73f21da | |
|
a5e643232e | |
|
3c5a43c8b7 | |
|
d829b95614 | |
|
24a205db07 | |
|
f0e28aed3e | |
|
a7167845a0 | |
|
a81febf611 | |
|
00a921f104 | |
|
09df1501dd | |
|
07decf3810 | |
|
471cabddc5 | |
|
3cc72aa4a6 | |
|
b54f57bb65 | |
![]() |
5bf2806f45 | |
|
11c3f8a6a8 | |
|
54c014aad4 | |
|
7fdd75b760 | |
|
d8737e201d | |
|
fffc2a695f | |
|
68f2c97275 | |
|
3458b841bf | |
![]() |
816cc37459 | |
![]() |
1926e44a2f | |
|
efcff5a8a1 | |
![]() |
0b10459a6d | |
|
d98af088be | |
|
3666d044cd | |
|
85b145a2f9 | |
|
dfe465b8c3 | |
|
a88b8cc557 | |
|
a8eafea5a7 | |
|
d2480b3635 | |
|
03bdbb4b39 | |
|
b899e24204 | |
|
7183c5bc2b | |
|
2abdf653b7 | |
|
48450e3f12 | |
|
8984f5ad8f | |
![]() |
78b7f58b83 | |
|
643f9862f3 | |
|
6698dca368 | |
![]() |
1618503db7 | |
|
543a846289 | |
![]() |
6fc7813d99 | |
|
a1de543215 | |
|
72bedb8de1 | |
![]() |
b58673ff79 | |
|
9992caa9dd | |
|
1d8247ad8b | |
![]() |
5417a4f4e3 | |
|
01a65d6b43 | |
|
fa8c38a425 | |
|
436a02c222 | |
|
e5fe314202 | |
|
edf50b8895 | |
![]() |
a9d5d5a799 | |
|
0494bae682 | |
|
095e28089e | |
|
11173951ac | |
|
07785345e6 | |
|
d2dbc6050d | |
|
fd3b449902 | |
|
c27d826707 | |
|
e9915f2f96 | |
|
080e2ba4fb | |
![]() |
a156ac3bc1 | |
|
ec7a9f1af8 | |
|
a8edadb6a6 | |
|
e6b7244b55 | |
|
de271eb4f9 | |
|
57671a5a90 | |
|
b0bf2a76a9 | |
|
52e9e6e390 | |
|
00cc70ef97 | |
|
49c0ac72ca | |
|
92c348ce58 | |
![]() |
b6aaa8f956 | |
|
31a0bf4ab2 | |
|
bb8f6a45a2 | |
![]() |
17ad6fb214 | |
|
e2c61413ed | |
![]() |
894d739b1d | |
|
cbaa676f56 | |
![]() |
b196dd7bcb | |
![]() |
0578c624ad | |
![]() |
c187c2d831 | |
|
c0a06e6e44 | |
|
bf6d33891f | |
|
3af5ba0aa4 | |
|
fe9144edbb | |
|
2d7af0e080 | |
|
efc0839ef2 | |
|
234ae8e54c | |
|
dc00f764c1 | |
|
9e20cb0942 | |
|
de0d990831 | |
|
66b80bd6f1 | |
|
09ace3e825 | |
|
e3861abdf1 | |
|
39323a8386 | |
![]() |
0a39781ba7 | |
|
ee8f33c028 | |
|
4db51463f0 | |
![]() |
e0e10c25b4 | |
|
c1afac3792 | |
|
a45a1bf941 | |
|
f55562e3fe | |
|
3a95c3c308 | |
![]() |
e892639169 | |
|
2959aac513 | |
|
748397d755 | |
|
587c562784 | |
|
f962c84764 | |
|
9bdec6939c | |
|
91d46594af | |
|
ccacf48515 | |
|
5525037b98 | |
|
a1074a19ea | |
|
d79e0e935c | |
![]() |
dc0b79cf97 | |
|
f4d4732e42 | |
|
52f30b7d38 | |
|
a9ff6d04f0 | |
|
20bb3b28de | |
![]() |
d062805633 | |
|
cefad1d0b4 | |
|
66aeaebbc2 | |
|
b28f090a38 | |
|
f7b344c06e | |
|
4be6cecec3 | |
|
67ac13c276 | |
|
f443ffece1 | |
|
b6a76849da | |
![]() |
a107e953c7 | |
|
f5bd632da4 | |
|
498bb11013 | |
|
6d618e8b26 | |
|
6becea02e0 | |
|
6125187c6f | |
|
a4b4bc4a18 | |
|
fb18f91688 | |
![]() |
7c3247965e | |
|
7dca44cce5 | |
|
d12d2b75ba | |
|
204d92f951 | |
![]() |
f4af40a70e | |
|
dd6d6f7e06 | |
|
5c331d73fb | |
|
1a4e7b5b8c | |
|
6ba2b6e40e | |
|
54e2cdec8c | |
|
d2aa65e62e | |
|
2920371940 | |
|
d4cae61b37 | |
|
f2c3486208 | |
|
70aeba8224 | |
![]() |
90ef5af9b3 | |
|
8d4befdcac | |
|
ddc60c62d4 | |
|
1642964e9e | |
|
c99540057e | |
|
66e29b3fe1 | |
|
ebc8bd8083 | |
![]() |
92681ec874 | |
![]() |
f42133fe30 | |
|
a43f9d6e24 | |
|
8b3f544850 | |
|
e2c0a72420 | |
![]() |
2711fe6655 | |
|
f63bcd8cd9 | |
![]() |
2abd2468b8 | |
|
9b1f354640 | |
|
635f485fd7 | |
![]() |
96fa855144 | |
![]() |
5ee798398d | |
![]() |
072d08a995 | |
![]() |
bc33f7a73d | |
![]() |
fea83c126f | |
|
87aa79b6fa | |
|
44379cd465 | |
|
39fda557fe | |
|
5eb520761c | |
|
8b62cd3019 | |
![]() |
8279288fd4 | |
|
2b32f1274f | |
|
77c18c1958 | |
![]() |
6c4cd0a7cf | |
![]() |
64998afaeb | |
|
03b2d4f18a | |
|
4bd01667bd | |
|
2562e20fb3 | |
|
f892275080 | |
![]() |
f4727bc937 | |
|
9b6aa07fb2 | |
|
5f5afa2635 | |
|
1add5a30c0 | |
|
6264e85a1d | |
|
6f32ec3761 | |
|
2c1c375456 | |
|
cd85b07022 | |
![]() |
5fea34375c | |
|
7f316ce14f | |
|
cd593eef6a | |
|
1d3048565f | |
|
7619f5099d | |
|
b93b2767cb | |
![]() |
a7bd9b497e | |
|
d981cb870a | |
|
97bccdacb1 | |
|
8bad138e2e | |
|
dd709d1db8 | |
|
0ee7391f32 | |
![]() |
3a50f1221c | |
![]() |
dc8321bd0a | |
|
5a5384ec27 | |
![]() |
909e40a9e1 | |
|
ab89040461 | |
![]() |
f23e72e92a | |
|
d10c31aa37 | |
![]() |
6af611dbf4 | |
|
4ebd6fde15 | |
|
e51901cf90 | |
|
b95b480f26 | |
|
6bc07a5b58 | |
|
a444847442 | |
|
f2b007d944 | |
|
a730c0afda | |
|
41adf19464 | |
|
34dde63017 | |
|
dcb1179e06 | |
![]() |
9276860d6a | |
|
8b7211ffe2 | |
|
3627ae2fc1 | |
|
f982efb7a7 | |
![]() |
bc922f3a9f | |
|
82918b202c | |
|
d59c24c6d5 | |
![]() |
a763929d37 | |
|
9823b73713 | |
![]() |
5e9f260c5a | |
|
213ab64305 | |
|
1e21aa708f | |
|
4d84ba0dbe | |
![]() |
c7f1ba9bff | |
|
fbb25b6bac | |
|
e470a7224e | |
![]() |
599ca53324 | |
|
275499591a | |
|
16d7a674ba | |
|
74e3de3cb1 | |
![]() |
dbc4f749ce | |
|
4f16985b82 | |
|
4a6fbbd47d | |
|
972833115b | |
|
5f35ace617 | |
|
fbdbb8d5cc | |
|
06d89c7283 | |
|
38ca23befb | |
|
d4394c219b | |
|
65b9eea27b | |
|
0def585aa2 | |
![]() |
9654c830d9 | |
|
52335cf647 | |
|
0e5728a3ac | |
![]() |
32b243ff67 | |
|
816e045d86 | |
|
c622595f41 | |
|
5d7bdc5698 | |
|
d4f4023a03 | |
|
83a5a02681 | |
|
53bb595232 | |
|
c1abb830d1 | |
|
2f871b0a8c | |
|
2fc216b678 | |
|
36ace9fb66 | |
![]() |
530f5fc43b | |
|
4bebbb2c3d | |
|
f62f838a5f | |
![]() |
c8011d412d | |
|
f126f90e15 | |
![]() |
de67e6b1ed | |
|
772eb111b6 | |
![]() |
232c92ddfe | |
|
359b651bf3 | |
|
5d2a630fec | |
|
de8437891b | |
|
8162469a7c | |
|
0f5dbc3727 | |
|
5ff1768bf7 | |
![]() |
03baa135c9 | |
![]() |
ed80e34a2b | |
|
c2a3d6c24b | |
![]() |
070ba6fd70 | |
|
8b4b151232 | |
|
ef39ee31c2 | |
|
d80b416d5d | |
|
0c34d1c01d | |
|
47c79ab180 | |
|
52f075f599 | |
|
580169aa1c | |
|
3a6a0c5562 | |
|
3cf90b76c8 | |
|
e03ca45fba | |
|
a511a21d6c | |
|
bb87ede423 | |
|
bb47d62c6d | |
|
d45d1a5e83 | |
|
79e2eeab40 | |
![]() |
a2b30c46ea | |
|
b2fd34789d | |
|
7449b8a3f8 | |
|
d174610659 | |
|
d5ab6f23f4 | |
|
17968a4ec8 | |
|
59f9ff5b3b | |
|
a896da28e6 | |
|
f705208b49 | |
|
80b3865224 | |
|
df26abf89d | |
|
dd6901abf4 | |
|
64f04c8fc3 | |
|
6e7f2aa32a | |
|
da4578f1b6 | |
|
c9a246a594 | |
|
62a922c3d5 | |
|
0be31fa70d | |
|
7bffc64c07 | |
|
a24753a0d6 | |
|
310b9cce61 | |
![]() |
473f182530 | |
![]() |
e2c49ca24d | |
![]() |
2560f79955 | |
|
5332413388 | |
![]() |
bd01b07705 | |
![]() |
47c76ae390 | |
|
40e1d9e0be | |
|
1d38838879 | |
|
c585f14b62 | |
![]() |
fd55f299b0 | |
|
45ccd77e2d | |
|
994afd9f9a | |
|
211ebb35d1 | |
|
ed0398528e | |
|
64f5a4762f | |
|
4f687d63b3 | |
![]() |
9535334b52 | |
|
aeae313118 | |
|
d2e9dcbb14 | |
|
8055113f42 | |
|
e0c5191028 | |
![]() |
a0cb40042b | |
|
549419ead7 | |
![]() |
2734b1103a | |
|
78cd3bbfe2 | |
![]() |
ab2756a3ff | |
|
dde9c49e3e | |
|
f7f931d761 | |
|
5084f35b4d | |
|
d8fe6a2489 | |
|
5436a0f92b | |
|
c63d9fa825 | |
![]() |
f06a021cdc | |
|
4a9ab995d8 | |
|
ec4e1e72b6 | |
|
557a5f74e3 | |
![]() |
e21a6917f4 | |
![]() |
a8e656db72 | |
|
02d95e82a3 | |
|
cc9b370610 | |
|
058a34e50b | |
|
ad79e432e0 | |
|
c0a511a143 | |
|
edc1cb0bc4 | |
|
fd21e564bc | |
|
b2f3e13f4c | |
|
1a8a02e00e | |
![]() |
a842cdc6fe | |
|
e20e0a4234 | |
|
e2c8cf69a9 | |
|
a2c4c8b963 | |
|
80dab8fbbb | |
|
d92f9106a2 | |
|
bd5e2f37fb | |
|
9b009c082d | |
|
5f12788a6e | |
|
813c8b8b6f | |
![]() |
24931fc038 | |
![]() |
1f108156ce | |
![]() |
c0bc784af5 | |
![]() |
3ea4cfcc7a | |
|
20f2976d9c | |
|
a510c817ad | |
|
3b8eb6d4fa | |
![]() |
567238a544 | |
|
c4d0937a80 | |
|
d4c09b853d | |
|
8ed8950070 | |
|
78cbd04cbe | |
|
c713c93ca6 | |
|
221f78672e | |
![]() |
a52750b5b2 | |
|
1a4c893be5 | |
|
027ff8174e | |
![]() |
1b1c5dde73 | |
|
809d02acd4 | |
|
e5ad910322 | |
|
00b2ee0316 | |
|
98fa34817e | |
|
351841d783 | |
![]() |
553b8491a1 | |
|
ee41eb8060 | |
|
9cfca09e14 | |
|
22c5ee79a2 | |
|
6735561cb1 | |
|
159748dc94 | |
![]() |
4576ed8274 | |
![]() |
361cfbd1d4 | |
|
f2785e8049 | |
|
5a4d79568e | |
|
7a30a23420 | |
|
6e26f38282 | |
|
9a330bd764 | |
|
a1864d9c22 | |
|
95161c70f1 | |
|
0385abbfb0 | |
|
ac0f45e07d | |
|
22fab6cfcb | |
|
a17e3c204b | |
|
2a31ca35ae | |
|
d2a40d7bf8 | |
|
45a44a341a | |
|
4b8b0a982e | |
![]() |
92c9b3a1b4 | |
|
ae014226d3 | |
![]() |
612c79b727 | |
![]() |
23a26e4f64 | |
|
6e6983dbd5 | |
|
ab6ef97a7c | |
|
fb7ef6ed77 | |
![]() |
a762b2b65a | |
![]() |
9ef032bc45 | |
![]() |
0995d2da62 | |
![]() |
c4faefa08d | |
|
685276d722 | |
|
9923ba639c | |
|
665371e110 | |
![]() |
1c118789e9 | |
|
d2773f9354 | |
|
e1139c6615 | |
|
a81de2fc09 | |
|
f1ae551270 | |
|
737e89c032 | |
|
86e59ae73e | |
![]() |
32324a8f28 | |
![]() |
d1804f269d | |
![]() |
8f15e02d06 | |
![]() |
749223671e | |
![]() |
b08aca37a7 | |
|
5f297d8130 | |
![]() |
5831fb7313 | |
|
25636ae069 | |
|
779278dbbf | |
|
b7c7f101e6 | |
|
1179c4b597 | |
|
f7d4edf34b | |
|
89edef6966 | |
|
8626a46aeb | |
![]() |
8d86e85a83 | |
|
3da3e1b53b | |
|
c67debb8e9 | |
|
4c5fadaea9 | |
|
7844ec69f2 | |
|
f10b7e2650 | |
|
dad4e2e27a | |
|
3347c10e69 | |
|
76205811d4 | |
|
e6ccb86129 | |
|
f60fdf516c | |
|
d47b047f91 | |
![]() |
aa5ae8acda | |
|
42c533e074 | |
|
c1967c813c | |
![]() |
26bfc432ab | |
![]() |
2762c234f0 | |
|
fecdb5fb80 | |
![]() |
cfe8e0def0 | |
|
c4995837d2 | |
![]() |
e661e9cc62 | |
|
2153c5492f | |
![]() |
e710c940f2 | |
|
b72c03ca6e | |
|
4a641184b4 | |
|
46f46f5646 | |
|
8f78dec90c | |
|
579155111a | |
![]() |
2fad05497d | |
|
3515ffea1b | |
|
7ada71ce27 | |
|
1cc1210e57 | |
|
27efef9e2a | |
|
a1c63eb82a | |
|
e0aa6b8b92 | |
|
c6f54c5292 | |
|
e733f670c7 | |
|
f8361b9ee7 | |
|
4d3904e62c | |
|
4dcf59086d | |
|
4e8a3404d3 | |
|
a2fd96350a | |
![]() |
85dac77d7c | |
|
755f962c29 | |
|
c16390f59a | |
|
62ab206b05 | |
|
5570c948df | |
|
8d5bffeed1 | |
|
cc51cf78fb | |
|
4415a188be | |
|
b2d2f0c2c0 | |
|
369e75285a | |
|
67bd78f730 | |
|
9926d4200c | |
|
2af2553182 | |
![]() |
e472da5e98 | |
|
56754eee39 | |
![]() |
d77db9542c | |
![]() |
3516c24a34 | |
|
7bae2ea653 | |
|
a4359ce117 | |
![]() |
c4d5f4906e | |
![]() |
f0f3ef7e38 | |
![]() |
9a71dc3aff | |
|
00e433dda9 | |
![]() |
a8c42c3a43 | |
![]() |
2b6b7d3e3e | |
![]() |
698220a161 | |
|
63a77ba345 | |
|
7102e94755 | |
|
e8040a7f2f | |
|
fb7221479e | |
|
0335020f97 | |
|
be152cfc31 | |
|
5b1d5d4097 | |
![]() |
ea0bf3a035 | |
![]() |
910337a6cf | |
|
103a4e3d3e | |
![]() |
9167317801 | |
|
63916cfffa | |
|
bc5f9954bb | |
|
05d11bd13f | |
|
c4bbd8c078 | |
|
5dcdeac867 | |
|
92075dd0f3 | |
|
0726e55e16 | |
|
ffd4655c6c | |
![]() |
7d3a8c61ce | |
|
71b4ec887b | |
![]() |
ced5cc32f6 | |
![]() |
8fff1be800 | |
|
3e65e7f451 | |
|
7cfce9aaee | |
![]() |
5c6140acc3 | |
|
dfb1a41512 | |
|
e945fa3a82 | |
|
eef8d278de | |
![]() |
eef7e3cda0 | |
![]() |
03d04b40f0 | |
|
74cd58bd62 | |
|
f59470e59e | |
![]() |
f554d3109b | |
|
9b3231537c | |
|
6fc2fcf59a | |
![]() |
a093a020c3 | |
|
50ba346e1d | |
|
9846bf697f | |
|
d17152539b | |
|
ae3dc285f5 | |
|
84cb22b6f6 | |
|
2d52e3a6a6 | |
|
3417612b5a | |
|
dc1330fc89 | |
|
8398b4d4f4 | |
![]() |
f76f90d84d | |
![]() |
ca752e5a3d | |
|
3a0d9b88b8 | |
![]() |
db9a395a4f | |
|
6414523ead | |
|
c8309b8acd | |
|
4a26e967e8 | |
|
aa81b37911 | |
|
1cfd8308bc | |
|
d6f1cb8636 | |
|
a77ae5628b | |
|
b45f70dfc5 | |
|
30ce3bf2a3 | |
![]() |
83ceaa7a3a | |
![]() |
3804379a43 | |
|
93872d34fb | |
![]() |
5a7d53f4ad | |
|
f20a7ec345 | |
![]() |
057859421c | |
|
38448cd13f | |
|
6f101a0544 | |
|
8e53a098d4 | |
|
2395b71ed7 | |
|
f96cb06077 | |
|
6b0586c53a | |
![]() |
21097c282b | |
|
b06349f723 | |
|
eec8e1db0c | |
|
43aca284b6 | |
|
03076de1cb | |
|
3fdf5f732c | |
|
ec7d167590 | |
|
c5f8370e0e | |
![]() |
c049ed3916 | |
|
981a9c5197 | |
|
a659e09fb4 | |
|
abc7026f9b | |
|
6560db3647 | |
|
16466d1a67 | |
![]() |
ec2c0160da | |
|
fd6159a208 | |
|
34c39433d0 | |
|
520dfd5c6e | |
![]() |
d22e5e6dba | |
|
166bdbff1c | |
|
2a9718bf30 | |
![]() |
1e0cd539b6 | |
|
af6d212481 | |
|
86e4d39fac | |
|
5fb46424fe | |
|
cf39debf55 | |
|
95021f596f | |
|
44e9a8eca9 | |
|
d534a22856 | |
|
b58c8986b6 | |
|
a87acd763d | |
|
57436c4a3e | |
![]() |
fd6fc4809d | |
![]() |
9806da15ae | |
|
f115264c4b | |
|
b17faafd6e | |
![]() |
3b9338184b | |
|
ff779b371a | |
![]() |
ce34f1134e | |
|
5217b1dc26 | |
![]() |
50a786b6c2 | |
|
9311072e75 | |
|
0a7c8c39a9 | |
|
c9033e585b | |
|
a3a3066422 | |
|
1e68d640a6 | |
|
ffc35bcb49 | |
|
c4e0715d8c | |
![]() |
0d332d85a3 | |
|
eb484b90d1 | |
![]() |
bbd1ec050c | |
![]() |
3a87646e12 | |
|
31f5da9d53 | |
![]() |
68c5383d93 | |
![]() |
091b554d35 | |
|
807d190108 | |
|
36a61516d9 | |
|
1348a0b1f4 | |
![]() |
d2b78ffd40 | |
![]() |
e89ab5408e | |
|
1cb0a56b0f | |
|
bf29c1c0df | |
![]() |
b3ebd271ec | |
![]() |
20d92e3354 | |
![]() |
157111f366 | |
![]() |
61125cc6f7 | |
|
3675bb7ab3 | |
|
3c7350912c | |
|
c7d3ba8920 | |
![]() |
abac731fe7 | |
|
93bb26441c | |
![]() |
94f1920151 | |
|
22ae8121db | |
|
5c97ebd302 | |
|
3f2bc2bc5f | |
|
6b8634f2e8 | |
|
edebb3425e | |
|
41534b71fe | |
![]() |
4532344eb0 | |
![]() |
a9ffbec8fa | |
|
1aa6543cf8 | |
![]() |
dec7157a7c | |
|
818c4c6756 | |
|
e9344f950b | |
|
913998815e | |
|
a95b3dd4c8 | |
|
8d5472a086 | |
|
90b4b77149 | |
|
c617b96962 | |
|
43789c6117 | |
![]() |
44b84d4f65 | |
|
a6d0b2fb95 | |
|
eafc29ccaf | |
|
97f5644233 | |
|
6e08e454d3 | |
|
63f4c62c85 | |
|
99b4ab1c68 | |
|
0f70cb55c1 | |
|
64d38a82f3 | |
|
e2396f17ec | |
|
3b0e18859f | |
|
0dcf3f088b | |
|
ab8fe8debd | |
|
bec8b79e99 | |
![]() |
f800a4faa9 | |
|
549992f75f | |
|
25210cd919 | |
|
57ca6777bf | |
|
b4402302df | |
|
b89343d516 | |
|
0a62599565 | |
|
86e05de253 | |
![]() |
c1a2785982 | |
|
2046fbd5eb | |
|
60b8f4714a | |
![]() |
0412003b74 | |
![]() |
334104b7dd | |
|
585a925679 | |
|
4672cf146a | |
|
f8f406e682 | |
![]() |
f4e4b14541 | |
![]() |
c620cab99e | |
|
09180d8dc2 | |
|
7be14bf439 | |
|
0fc4088ceb | |
|
e9c26c14bb | |
|
592cbdca8c | |
|
d278b6b246 | |
|
d15ecc8d9d | |
![]() |
6f45ecd676 | |
|
e63d4e28f9 | |
|
2b3b4d6686 | |
|
d98133b6c7 | |
![]() |
4c72b26c92 | |
|
5c7bbd0074 | |
|
3b50bae37e | |
|
b8c0b2ea83 | |
|
4f26f5a397 | |
|
cefc3b9dc8 | |
|
7987fa7c4b | |
|
e3619ba428 | |
|
5fd98c89d2 | |
|
b7b956fccb | |
|
a9d6c7c05b | |
|
e1e095e18d | |
|
bce716e8e3 | |
|
186cc9ecd9 | |
|
b8cccec142 | |
|
42e0b87c7e | |
|
e7a1be0416 | |
![]() |
9bfbcdeb95 | |
|
816fce1fbb | |
|
d6baf1333a | |
|
081db0615e | |
|
4244efa037 | |
|
4005085ca7 | |
|
8994642ac8 | |
|
836a476bde | |
|
79e824ad75 | |
|
e17f1d691f | |
![]() |
8e0a6baaee | |
|
dbb25110da | |
![]() |
d7d8e3836e | |
![]() |
7b6c61467c | |
|
c64e80b033 | |
|
8a1cf9e74c | |
|
99ea55376b | |
|
c8dd9fcae8 | |
![]() |
53e037c988 | |
|
d325d51399 | |
|
ac79dbf7be | |
|
92c1b9aa5e | |
|
90b3153080 | |
|
f77cdcfd58 | |
|
368a576ac2 | |
|
623b25c034 | |
![]() |
db117d8122 | |
![]() |
0eadacdc85 | |
|
7dc7f9723a | |
|
060d0fbae6 | |
|
ee19975f23 | |
|
a2f44794f3 | |
|
828677f7a7 | |
![]() |
4cc4887997 | |
![]() |
1eb7c38e22 | |
|
6d57b0c5b8 | |
![]() |
6466355236 | |
|
088c424cac | |
|
b6bbaef3ab | |
![]() |
c0509efdba | |
![]() |
6e8863d2a8 | |
![]() |
fcdca91a79 | |
![]() |
36cc1a25bd | |
|
52ed80ca1a | |
|
c6a977d6cd | |
![]() |
291e2c50da | |
|
b853dc83c5 | |
![]() |
1e042e987e | |
![]() |
8bd7521828 | |
|
6ad6a8bd52 | |
|
18cf524c5b | |
|
cc66b9879e | |
|
16fffe41ed | |
![]() |
6e8f2247df | |
![]() |
7f96623ca7 | |
![]() |
8b0c37b572 | |
|
57fdb94992 | |
|
ed08c607a1 | |
|
af98dd93ab | |
![]() |
dce7f29e75 | |
|
81413a90e2 | |
|
564d2a36bd | |
![]() |
f000b10c24 | |
![]() |
c25692da8c | |
![]() |
c9dd48f4f4 | |
|
cac5aa18a3 | |
|
5c8ea33af0 | |
![]() |
987a873d7b | |
![]() |
12f204dda8 | |
|
2b3533ea03 | |
|
bf41507476 | |
|
3bc3e63a78 | |
|
553223bffc | |
|
7d98fadf4f | |
|
c76108ee3c | |
|
170604f144 | |
![]() |
43c6478f90 | |
![]() |
57e276875d | |
|
d635aa9d05 | |
|
cdd7fd5016 | |
|
9f2ca4b559 | |
![]() |
cddfda4e67 | |
![]() |
9a3a7f9fc7 | |
|
b991f7e448 | |
|
29ab94dbd7 | |
|
9bf55ff4f6 | |
![]() |
553810f238 | |
|
3865101b68 | |
|
03333b7b48 | |
![]() |
0355f6d039 | |
|
c73ec85807 | |
|
34c6857797 | |
|
721b44ead0 | |
|
c616d9df75 | |
|
a7ee0cef83 | |
![]() |
973fe9382d | |
![]() |
40a1cff9aa | |
|
90a2f3eb23 | |
|
7ce1ed3a5c | |
|
01f69d9c0c | |
|
b90ca86a26 | |
![]() |
3457ee7203 | |
![]() |
fc801ff512 | |
|
6cc699ea56 | |
![]() |
f88cc5e90d | |
|
2e0fe9c877 | |
|
66d8f90a03 | |
![]() |
abf297893f | |
|
39236f372c | |
|
2c0d49d1f9 | |
|
a8d3fc646c | |
|
143f3ca44b | |
![]() |
1d70f1c10f | |
|
d748895723 | |
|
42eaadc50a | |
|
6a9314f63a | |
|
f7325bab22 | |
![]() |
f9505a4c66 | |
![]() |
ffdab0fd14 | |
|
9f4fa06c1e | |
|
88a62e5c27 | |
![]() |
a6229ab11e | |
|
7b6f609aae | |
|
b93cd0fae0 | |
|
b1f0cb902f | |
|
e783172631 | |
|
f28383ee90 | |
|
e9e0604ac3 | |
|
54740e6e74 | |
|
1af157a0b8 | |
|
5012be7a43 | |
|
b116266efd | |
|
40ea58280e | |
|
6df96a3ebe | |
|
a7148185c5 | |
![]() |
e521fffc57 | |
|
10a64f3cdf | |
![]() |
5709c98208 | |
|
c552f924ff | |
|
513d41a48f | |
|
23a8e86f64 | |
![]() |
1592137e0b | |
|
390889e022 | |
|
6e7260687a | |
|
938f3260a7 | |
|
12fde16665 | |
|
4030fed408 | |
![]() |
06d93e0cc0 | |
![]() |
5ce5e9c952 | |
|
5681970164 | |
![]() |
6ac9e8e2ed | |
|
37afe1cc2f | |
|
45884b52fb | |
|
294399e07a | |
|
7b0ff87e3e | |
|
c64a2c910b | |
![]() |
7eea870b92 | |
|
f347ad45fb | |
|
ec556176b9 | |
![]() |
bfe288b68a | |
|
8c207c989e | |
|
ca3733bfe5 | |
![]() |
6583be2ae2 | |
|
72c34eb4cf | |
|
e1025c7c09 | |
![]() |
2710390206 | |
|
66dcb1f2d6 | |
![]() |
42d2401293 | |
|
0fc68a1503 | |
|
637f9c16d7 | |
|
b278dd7d88 | |
|
fd7d3cfc5a | |
![]() |
ad8fd2940d | |
![]() |
c87f952f08 | |
|
f9e4fe6702 | |
![]() |
42beb81450 | |
![]() |
fbc3539f31 | |
|
3f9db0313a | |
|
3e3d75f7cf | |
|
a9e547cc2b | |
|
8859bc731d | |
|
3e0ff8e463 | |
|
acbee91868 | |
|
f0d0ff7188 | |
|
a4b4fcec76 | |
|
b4aa3c71d1 | |
|
adbaa9e86f | |
|
0a7eba5a90 | |
|
9d43165b68 | |
|
6d5c49cef6 | |
|
f1c1a1b5bc | |
![]() |
5522232189 | |
|
cc2dfbd902 | |
|
e9b2e12242 | |
|
6eb7f1345d | |
|
2f26a73617 | |
|
7542fdbdb5 | |
|
691b7de54d | |
|
25c7f3a737 | |
|
f5a40e298c | |
|
1e9eb5d90d | |
|
1410b6d4dc | |
|
6ec0c182b2 | |
|
1e67e1a130 | |
|
1f3b82199f | |
|
d60cd6951f | |
![]() |
ab73e9e85f | |
![]() |
6aa5cab829 | |
|
3af93cbc55 | |
|
9818117c76 | |
|
9e0d46f2dc | |
|
3324fea63f | |
![]() |
4d27650f1d | |
|
99b02e4d85 | |
|
20a79af53e | |
![]() |
637eb20bde | |
|
3ae59185b2 | |
|
ab20a8e2b4 | |
![]() |
a8a3fe0ee9 | |
![]() |
37b69b8737 | |
|
fabf4c075d | |
|
ca371e1531 | |
|
41e5b33ea5 | |
|
66e5698a80 | |
|
1174307dba | |
|
0478d1b839 | |
|
c5e8bb6845 | |
![]() |
f79b4680d1 | |
|
2156b68c28 | |
|
6e14e247ea | |
|
5e8bce0894 | |
![]() |
5aa233878f | |
![]() |
788311123d | |
|
616661bd1e | |
|
e112b34d4b | |
|
b1382db7ba | |
|
5fc4e673fb | |
![]() |
101574e8ee | |
|
e29f61ad38 | |
![]() |
e4286befb5 | |
|
d9eb1b21ec | |
|
2ef17714e9 | |
![]() |
b947e38785 | |
![]() |
3b1fa6b7f7 | |
|
a58410716d | |
|
b882dc8c81 | |
![]() |
166c955fea | |
|
fd7550a45e |
.jenkins/check/config
README.mdREADME_CN.mdRELEASE.mdRELEASE_CN.mdakgcmake
config
docs
MindSpore-architecture-zh.pngMindSpore-architecture.png
api/api_python
amp
mindspore.amp.DynamicLossScaler.rstmindspore.amp.LossScaleManager.rstmindspore.amp.StaticLossScaler.rstmindspore.amp.all_finite.rstmindspore.amp.init_status.rst
dataset
mindspore.dataset.AGNewsDataset.rstmindspore.dataset.AmazonReviewDataset.rstmindspore.dataset.ArgoverseDataset.rstmindspore.dataset.BuiltinSampler.b.rstmindspore.dataset.CLUEDataset.rstmindspore.dataset.CSVDataset.rstmindspore.dataset.Caltech256Dataset.rstmindspore.dataset.CelebADataset.rstmindspore.dataset.Cifar100Dataset.rstmindspore.dataset.Cifar10Dataset.rstmindspore.dataset.CityscapesDataset.rstmindspore.dataset.CoNLL2000Dataset.rstmindspore.dataset.CocoDataset.rstmindspore.dataset.DBpediaDataset.rstmindspore.dataset.DIV2KDataset.rstmindspore.dataset.DSCallback.rstmindspore.dataset.Dataset.c.rstmindspore.dataset.Dataset.e.rstmindspore.dataset.Dataset.rstmindspore.dataset.DatasetCache.rstmindspore.dataset.EMnistDataset.rstmindspore.dataset.EnWik9Dataset.rstmindspore.dataset.FakeImageDataset.rstmindspore.dataset.FashionMnistDataset.rstmindspore.dataset.FlickrDataset.rstmindspore.dataset.Flowers102Dataset.rstmindspore.dataset.GeneratorDataset.rstmindspore.dataset.Graph.rstmindspore.dataset.GraphData.rstmindspore.dataset.IMDBDataset.rstmindspore.dataset.IWSLT2016Dataset.rstmindspore.dataset.IWSLT2017Dataset.rstmindspore.dataset.ImageFolderDataset.rstmindspore.dataset.InMemoryGraphDataset.rstmindspore.dataset.KMnistDataset.rstmindspore.dataset.LJSpeechDataset.rstmindspore.dataset.ManifestDataset.rstmindspore.dataset.MindDataset.rstmindspore.dataset.MnistDataset.rstmindspore.dataset.PennTreebankDataset.rstmindspore.dataset.PhotoTourDataset.rstmindspore.dataset.Places365Dataset.rstmindspore.dataset.QMnistDataset.rstmindspore.dataset.RandomDataset.rstmindspore.dataset.SBDataset.rstmindspore.dataset.SBUDataset.rstmindspore.dataset.STL10Dataset.rstmindspore.dataset.SVHNDataset.rstmindspore.dataset.SemeionDataset.rstmindspore.dataset.SogouNewsDataset.rstmindspore.dataset.SpeechCommandsDataset.rstmindspore.dataset.TFRecordDataset.rstmindspore.dataset.TedliumDataset.rstmindspore.dataset.TextFileDataset.rstmindspore.dataset.UDPOSDataset.rstmindspore.dataset.USPSDataset.rstmindspore.dataset.VOCDataset.rstmindspore.dataset.WIDERFaceDataset.rstmindspore.dataset.WaitedDSCallback.rstmindspore.dataset.WikiTextDataset.rstmindspore.dataset.YahooAnswersDataset.rstmindspore.dataset.YelpReviewDataset.rstmindspore.dataset.YesNoDataset.rstmindspore.dataset.deserialize.rstmindspore.dataset.serialize.rstmindspore.dataset.show.rstmindspore.dataset.utils.imshow_det_bbox.rst
dataset_audio
dataset_text
dataset_vision
mindrecord
|
@ -7,6 +7,7 @@
|
|||
"mindspore/mindspore/core/abstract/ops/prim_nn.cc" "zerodivcond"
|
||||
"mindspore/mindspore/ccsrc/frontend/operator/ops_front_infer_function.cc" "zerodivcond"
|
||||
"mindspore/mindspore/ccsrc/pipeline/jit/pipeline_split.cc" "zerodivcond"
|
||||
"mindspore/mindspore/ccsrc/plugin/device/ascend/kernel/aicpu/aicpu_ops/drop_out_gen_mask_kernels.cc" "uninitMemberVar"
|
||||
"mindspore/mindspore/ccsrc/plugin/device/ascend/optimizer/ir_fusion/adaptive_max_pool2d_fusion.cc" "zerodivcond"
|
||||
"mindspore/mindspore/ccsrc/plugin/device/ascend/hal/device/ascend_stream_assign.cc" "useStlAlgorithm"
|
||||
"mindspore/mindspore/ccsrc/frontend/operator/ops_front_infer_function.cc" "uninitvar"
|
||||
|
@ -66,3 +67,4 @@
|
|||
"mindspore/mindspore/lite/src/litert/kernel/cpu/fp32/convolution_im2col_fp32.cc" "shadowVariable"
|
||||
"mindspore/mindspore/lite/src/litert/kernel/cpu/fp32/convolution_winograd_fp32.cc" "knownConditionTrueFalse"
|
||||
"mindspore/mindspore/lite/src/litert/kernel/cpu/fp32/convolution_winograd_fp32.cc" "shadowVariable"
|
||||
"mindspore/mindspore/ccsrc/plugin/device/ascend/kernel/tbe/tbe_utils.cc" "knownConditionTrueFalse"
|
||||
|
|
|
@ -20,7 +20,9 @@
|
|||
"mindspore/mindspore/ccsrc/runtime/hardware/device_context.h" "readability/braces"
|
||||
"mindspore/mindspore/ccsrc/transform/graph_ir/convert.h" "runtime/references"
|
||||
"mindspore/mindspore/ccsrc/plugin/device/ascend/kernel/aicpu/aicpu_ops/gather_grad_kernels.cc" "build/include"
|
||||
"mindspore/mindspore/ccsrc/plugin/device/ascend/kernel/aicpu/aicpu_ops/drop_out_gen_mask_kernels.cc" "build/include"
|
||||
"mindspore/mindspore/ccsrc/backend/common/optimizer/op_adaptation_info_factory.h" "runtime/explicit"
|
||||
"mindspore/mindspore/ccsrc/plugin/device/gpu/kernel/cuda_impl/cuda_ops/concatv2_impl.cu" "runtime/int"
|
||||
|
||||
# Modelzoo
|
||||
"mindspore/model_zoo/official/cv/yolov4_tiny/infer/mxbase/src/Yolov4TinyDetection.h" "runtime/references"
|
||||
|
|
|
@ -49,8 +49,12 @@ https://github.com/siju-samuel/darknet/blob/master/
|
|||
https://developer.download.nvidia.cn/compute/cuda/repos/ubuntu
|
||||
https://developer.download.nvidia.cn/compute/machine-learning/repos/ubuntu
|
||||
https://dl.google.com/dl/android/maven2/
|
||||
https://ms-release.obs.cn-north-4.myhuaweicloud.com/1.8.0/MindInsight/any/mindinsight-1.8.0-py3-none-any.whl
|
||||
https://ms-release.obs.cn-north-4.myhuaweicloud.com/1.8.0/MindSpore/cpu/x86_64/mindspore-1.8.0-cp37-cp37m-linux_x86_64.whl
|
||||
https://ms-release.obs.cn-north-4.myhuaweicloud.com/1.8.0/Serving/x86_64/mindspore_serving-1.8.0-cp37-cp37m-linux_x86_64.whl
|
||||
https://ms-release.obs.cn-north-4.myhuaweicloud.com/1.8.0/MindSpore/gpu/x86_64/cuda-10.1/mindspore_gpu-1.8.0-cp37-cp37m-linux_x86_64.whl
|
||||
https://ms-release.obs.cn-north-4.myhuaweicloud.com/1.8.0/MindSpore/gpu/x86_64/cuda-11.1/mindspore_gpu-1.8.0-cp37-cp37m-linux_x86_64.whl
|
||||
https://ms-release.obs.cn-north-4.myhuaweicloud.com/1.9.0/MindInsight/any/mindinsight-1.9.0-py3-none-any.whl
|
||||
https://ms-release.obs.cn-north-4.myhuaweicloud.com/1.9.0/MindSpore/cpu/x86_64/mindspore-1.9.0-cp37-cp37m-linux_x86_64.whl
|
||||
https://ms-release.obs.cn-north-4.myhuaweicloud.com/1.9.0/Serving/x86_64/mindspore_serving-1.9.0-cp37-cp37m-linux_x86_64.whl
|
||||
https://ms-release.obs.cn-north-4.myhuaweicloud.com/1.9.0/MindSpore/gpu/x86_64/cuda-10.1/mindspore_gpu-1.9.0-cp37-cp37m-linux_x86_64.whl
|
||||
https://ms-release.obs.cn-north-4.myhuaweicloud.com/1.9.0/MindSpore/gpu/x86_64/cuda-11.1/mindspore_gpu-1.9.0-cp37-cp37m-linux_x86_64.whl
|
||||
https://mindspore.cn*/r1.9/*
|
||||
https://www.mindspore.cn*/r1.9/*
|
||||
https://mindspore.cn*/r1.10/*
|
||||
https://www.mindspore.cn*/r1.10/*
|
||||
|
|
|
@ -155,9 +155,11 @@
|
|||
"mindspore/tests/st/ops/ascend/test_aicpu_ops/test_strided_slice_grad.py" "redefined-outer-name"
|
||||
"mindspore/tests/st/pynative/parser/test_parser_construct.py" "bad-super-call"
|
||||
"mindspore/tests/ut/python/optimizer/test_auto_grad.py" "broad-except"
|
||||
"mindspore/tests/st/gradient/test_grad_return_type.py" "unused-variable"
|
||||
"mindspore/tests/st/fallback/control_flow/test_fallback_100_if_after_if.py" "unused-variable"
|
||||
"mindspore/tests/st/numpy_native/test_array_ops.py" "useless-super-delegation"
|
||||
"mindspore/tests/ut/python/mindir/test_mindir_export.py" "no-else-return"
|
||||
"mindspore/tests/" "c-extension-no-member"
|
||||
|
||||
#MindSpore Lite
|
||||
"mindspore/mindspore/ccsrc/plugin/device/cpu/kernel/nnacl/experimental/HPC-generator/generator.py" "redefined-builtin"
|
||||
|
|
|
@ -20,6 +20,7 @@ mindspore/mindspore/ccsrc/pipeline/jit/static_analysis/prim.cc:mindspore::abstra
|
|||
mindspore/mindspore/ccsrc/pybind_api/ir/log_adapter_py.cc:mindspore::PyExceptionInitializer::HandleExceptionPy
|
||||
mindspore/mindspore/ccsrc/plugin/device/gpu/kernel/math/unary_op_gpu_kernel.h:mindspore::kernel::UnaryOpGpuKernel::Launch
|
||||
mindspore/mindspore/ccsrc/plugin/device/ascend/optimizer/ir_fission/dynamic_rnn_grad_fission_v2.cc:mindspore::opt::AddLSTMInputGradNode
|
||||
mindspore/mindspore/ccsrc/plugin/device/ascend/kernel/aicpu/aicpu_ops/drop_out_gen_mask_kernels.cc:aicpu::ARMDropOutGenMaskKernel
|
||||
mindspore/model_zoo/official/recommend/wide_and_deep/src/wide_and_deep.py:__init__
|
||||
mindspore/model_zoo/official/recommend/wide_and_deep_multitable/src/wide_and_deep.py:__init__
|
||||
mindspore/mindspore/ccsrc/pipeline/jit/resource.cc:mindspore::pipeline::GetMethodMap
|
||||
|
|
|
@ -281,11 +281,13 @@ Project stable branches will be in one of the following states:
|
|||
|
||||
| **Branch** | **Status** | **Initial Release Date** | **Next Phase** | **EOL Date**|
|
||||
|------------|--------------|--------------------------|----------------------------------------|-------------|
|
||||
| **r1.10** | Maintained | 2023-02-02 | Unmaintained <br> 2024-02-02 estimated | |
|
||||
| **r1.9** | Maintained | 2022-10-26 | Unmaintained <br> 2023-10-26 estimated | |
|
||||
| **r1.8** | Maintained | 2022-07-29 | Unmaintained <br> 2023-07-29 estimated | |
|
||||
| **r1.7** | Maintained | 2022-04-29 | Unmaintained <br> 2023-04-29 estimated | |
|
||||
| **r1.6** | Maintained | 2022-01-29 | Unmaintained <br> 2023-01-29 estimated | |
|
||||
| **r1.5** | Maintained | 2021-10-15 | Unmaintained <br> 2022-10-15 estimated | |
|
||||
| **r1.4** | Maintained | 2021-08-15 | Unmaintained <br> 2022-08-15 estimated | |
|
||||
| **r1.6** | End Of Life | 2022-01-29 | | 2023-01-29 |
|
||||
| **r1.5** | End Of Life | 2021-10-15 | | 2022-10-15 |
|
||||
| **r1.4** | End Of Life | 2021-08-15 | | 2022-08-15 |
|
||||
| **r1.3** | End Of Life | 2021-07-15 | | 2022-07-15 |
|
||||
| **r1.2** | End Of Life | 2021-04-15 | | 2022-04-29 |
|
||||
| **r1.1** | End Of Life | 2020-12-31 | | 2021-09-30 |
|
||||
|
|
|
@ -274,11 +274,13 @@ MindSpore的版本分支有以下几种维护阶段:
|
|||
|
||||
| **分支名** | **当前状态** | **上线时间** | **后续状态** | **EOL 日期**|
|
||||
|------------|--------------|----------------------|----------------------------------------|------------|
|
||||
| **r1.10** | Maintained | 2023-02-02 | Unmaintained <br> 2024-02-02 estimated | |
|
||||
| **r1.9** | Maintained | 2022-10-26 | Unmaintained <br> 2023-10-26 estimated | |
|
||||
| **r1.8** | Maintained | 2022-07-29 | Unmaintained <br> 2023-07-29 estimated | |
|
||||
| **r1.7** | Maintained | 2022-04-29 | Unmaintained <br> 2023-04-29 estimated | |
|
||||
| **r1.6** | Maintained | 2022-01-29 | Unmaintained <br> 2023-01-29 estimated | |
|
||||
| **r1.5** | Maintained | 2021-10-15 | Unmaintained <br> 2022-10-15 estimated | |
|
||||
| **r1.4** | Maintained | 2021-08-15 | Unmaintained <br> 2022-08-15 estimated | |
|
||||
| **r1.6** | End Of Life | 2022-01-29 | | 2023-01-29 |
|
||||
| **r1.5** | End Of Life | 2021-10-15 | | 2022-10-15 |
|
||||
| **r1.4** | End Of Life | 2021-08-15 | | 2022-08-15 |
|
||||
| **r1.3** | End Of Life | 2021-07-15 | | 2022-07-15 |
|
||||
| **r1.2** | End Of Life | 2021-04-15 | | 2022-04-29 |
|
||||
| **r1.1** | End Of Life | 2020-12-31 | | 2021-09-30 |
|
||||
|
|
158
RELEASE.md
158
RELEASE.md
|
@ -2,7 +2,123 @@
|
|||
|
||||
[查看中文](./RELEASE_CN.md)
|
||||
|
||||
# MindSpore 1.8.1
|
||||
## MindSpore 1.10.1 Release Notes
|
||||
|
||||
### Bug fixes
|
||||
|
||||
- Fixed the issue that the specified axis is not considered in logsumexp anti-overflow processing
|
||||
- Fixed the compilation dependency of proto file
|
||||
- Fixed the issue that the print operator printing result is not normal
|
||||
- Fixed the issue that the equal operator is out of range
|
||||
- Fixed the problem that when function wrapped by @jit,the cell id is not correct
|
||||
- Fixed the GNN scenario data type verification error
|
||||
- Fixed the problem that the dataset.map multi-process degenerates into threads
|
||||
|
||||
### Contributors
|
||||
|
||||
Thanks goes to these wonderful people:
|
||||
|
||||
archer2049, caifubi, chenfei_mindspore, gaoshuanglong, Greatpan, guozhijian, huoxinyou, Kxiong, lanzhineng, lijunbin, liubuyu, liuchuting, luochao60, lyqlola, nomindcarry, TuDouNi, xiaotianci, xupan, yangshuo, yefeng, YingtongHu, yuchaojie, zhoufeng, ZPaC, 刘勇琪, 吕昱峰, 王禹程, 于振华.
|
||||
|
||||
Contributions of any kind are welcome!
|
||||
|
||||
## MindSpore 1.10.0 Release Notes
|
||||
|
||||
### Major Features and Improvements
|
||||
|
||||
#### DataSet
|
||||
|
||||
- [STABLE]The timeout waiting time is adjusted in data sinking mode. The default value is 600s after adjusted. This solves the isuses that the GetNext operator may timeout due to environment resource competition and large computing workload when training in sink mode.
|
||||
|
||||
### Bug fixes
|
||||
|
||||
- Fixed an issue where some Primitive operators in AMP cannot be instantiated in graph mode and the interface is unavailable.
|
||||
- Fixed an issue of DynamicRNN execution failure in LSTM network under the scenario of computational force segmentation on Ascend platform.
|
||||
- Fixed DEVICE_ID cannot be set by single card train scripts parameters in mobilenet, fasterrcnn, yolo, etc.
|
||||
|
||||
### Contributors
|
||||
|
||||
Thanks goes to these wonderful people:
|
||||
|
||||
AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bingyaweng, BowenK, buxue, caifubi, CaoJian, caojian05, caozhou, Cathy, changzherui, chenbo116, chenfei, chengxianbin, chenhaozhe, chenjianping, chenzomi, chenzupeng, chujinjin, cj, cjh9368, Corleone, damon0626, danish, Danish, davidmc, dayschan, doitH, dong-li001, fary86, fuzhiye, Gaoxiong, GAO_HYP_XYJ, gengdongjie, Gogery, gongdaguo, gray0v0, gukecai, guoqi, gzhcv, hangq, hanhuifeng2020, Harshvardhan, He, heleiwang, hesham, hexia, Hoai, HuangBingjian, huangdongrun, huanghui, huangxinjing, huqi, huzhifeng, hwjiaorui, Jiabin Liu, jianghui58, Jiaqi, jin-xiulang, jinyaohui, jjfeing, John, jonyguo, JulyAi, jzg, kai00, kingfo, kingxian, kpy, kswang, liuyongqi, laiyongqiang, leonwanghui, liangchenghui, liangzelang, lichen_101010, lichenever, lihongkang, lilei, limingqi107, ling, linqingke, Lin Xh, liubuyu, liuwenhao4, liuxiao78, liuxiao93, liuyang_655, liuzhongkai, Lixia, lixian, liyanliu, liyong, lizhenyu, luopengting, lvchangquan, lvliang, lz, maning202007, Margaret_wangrui, mengyuanli, Ming_blue, ms_yan, ougongchang, panfengfeng, panyifeng, Payne, Peilin, peixu_ren, Pengyongrong, qianlong, qianjiahong, r1chardf1d0, riemann_penn, rmdyh, Sheng, shenwei41, simson, Simson, Su, sunsuodong, tao_yunhao, tinazhang, VectorSL, , Wan, wandongdong, wangdongxu, wangmin, wangyue01, wangzhe, wanyiming, Wei, wenchunjiang, wilfChen, WilliamLian, wsc, wudenggang, wukesong, wuweikang, wuxuejian, Xiao Tianci, Xiaoda, xiefangqi, xinyunfan, xuanyue, xuyongfei, yanghaitao, yanghaitao1, yanghaoran, YangLuo, yangruoqi713, yankai, yanzhenxiang2020, yao_yf, yepei6, yeyunpeng, Yi, yoni, yoonlee666, yuchaojie, yujianfeng, yuximiao, zengzitao, Zhang, zhanghuiyao, zhanghui_china, zhangxinfeng3, zhangyihui, zhangz0911gm, zhanke, zhanyuan, zhaodezan, zhaojichen, zhaoting, zhaozhenlong, zhengjun10, zhiqwang, zhoufeng, zhousiyi, zhouyaqiang, zhouyifengCode, Zichun, Ziyan, zjun, ZPaC, wangfengwfwf, zymaa, gerayking, shu-kun-zhang.
|
||||
|
||||
Contributions of any kind are welcome!
|
||||
|
||||
## MindSpore Lite 1.10.0 Release Notes
|
||||
|
||||
### Bug fixes
|
||||
|
||||
- Fixed potential accuracy problem of arithmetic type CPU kernels at dynamical shape case.
|
||||
- Fixed the Incorrect Write Address of the Deconv Quantization Operator.
|
||||
|
||||
## MindSpore 1.9.0 Release Notes
|
||||
|
||||
### Major Features and Improvements
|
||||
|
||||
#### FrontEnd
|
||||
|
||||
- [STABLE] Add the object-oriented and functional combination programming paradigm, add mixed-precision APIs for combination programming paradigms such as `mindspore.amp.LossScaler`, `mindspore.amp.DynamicLossScaler`, `mindspore.amp.StaticLossScaler`, `mindspore.amp.auto_mixed_precision` and `mindspore.amp.all_finite`.
|
||||
|
||||
### API Change
|
||||
|
||||
#### operator
|
||||
|
||||
- [STABLE] Add nn interface for `nn.AdaptiveAvgPool3d`.
|
||||
- [STABLE] Add functional interface for `ops.adaptive_avg_pool3d`.
|
||||
- [STABLE] Add functional interface for `ops.addcdiv`.
|
||||
- [STABLE] Add functional interface for `ops.addcmul`.
|
||||
- [STABLE] Add GPU and CPU support for `ops.approximate_equal`.
|
||||
- [STABLE] Add GPU support for `ops.atanh`.
|
||||
- [STABLE] Add GPU support for `ops.bessel_i0`.
|
||||
- [STABLE] Add Ascend support for `ops.bessel_i0e`.
|
||||
- [STABLE] Add GPU support for `ops.bessel_i1`.
|
||||
- [STABLE] Add Ascend and GPU support for `ops.bessel_i1e`.
|
||||
- [STABLE] Add GPU support for `ops.bessel_j0`.
|
||||
- [STABLE] Add GPU support for `ops.bessel_j1`.
|
||||
- [STABLE] Add GPU support for `ops.bessel_k0`.
|
||||
- [STABLE] Add GPU support for `ops.bessel_k0e`.
|
||||
- [STABLE] Add GPU support for `ops.bessel_k1`.
|
||||
- [STABLE] Add GPU support for `ops.bessel_k1e`.
|
||||
- [STABLE] Add GPU support for `ops.bessel_y0`.
|
||||
- [STABLE] Add GPU support for `ops.bessel_y1`.
|
||||
- [STABLE] Add functional interface for `ops.bias_add`.
|
||||
- [STABLE] Add GPU support for `ops.bitwise_and`.
|
||||
- [STABLE] Add GPU support for `ops.bitwise_or`.
|
||||
- [STABLE] Add GPU support for `ops.bitwise_xor`.
|
||||
- [STABLE] Add Ascend support for `ops.grid_sample`.
|
||||
- [STABLE] Add CPU support for `ops.inplace_update`.
|
||||
- [STABLE] Add Ascend and GPU support for `ops.isclose`.
|
||||
- [STABLE] Add Ascend support for `ops.isnan`.
|
||||
- [STABLE] Add GPU support for `ops.lerp`.
|
||||
- [STABLE] Add functional interface for `ops.random_poisson`.
|
||||
- [STABLE] Add functional interface for `ops.reverse_sequence`.
|
||||
- [STABLE] Add GPU support for `ops.scatter_mul`.
|
||||
- [STABLE] Add functional interface for `ops.scatter_nd_max`.
|
||||
- [STABLE] Add functional interface for `ops.scatter_nd_min`.
|
||||
- [STABLE] Add GPU support for `ops.SparseToDense`.
|
||||
- [STABLE] Add functional interface for `ops.square`.
|
||||
- [STABLE] Add GPU support for `ops.standard_laplace`.
|
||||
- [STABLE] Add functional interface for `ops.std`.
|
||||
- [STABLE] Add Ascend and GPU support for `ops.trunc`.
|
||||
- [STABLE] Add functional interface for `ops.unsorted_segment_sum`.
|
||||
- [STABLE] Add functional interface for `ops.xdivy`.
|
||||
- [STABLE] Add GPU support for `ops.xlogy`.
|
||||
- Deprecate `ops.poisson` and use `ops.random_poisson` instead.
|
||||
- Deprecate `ops.SparseApplyAdagrad` and use `ops.SparseApplyAdagradV2` instead.
|
||||
|
||||
### Bug fixes
|
||||
|
||||
- [BUGFIX] The logic of the auto mixed precision (amp) O2 level is revised. In addition to the `BatchNorm1d` and `BatchNorm2d` operators, the other two operators `BatchNorm3d` and `LayerNorm` are added. The four operators still use the float32 data type when calculating.
|
||||
|
||||
- [BUGFIX] Fix the problem that when processing string type data, if `output_numpy=True` is specified when calling the `create_dict_iterator` or `create_tuple_iterator` interface, the obtained data will be of type `numpy.bytes_`. After this fixing, these interfaces will directly return `numpy.str_` type data, and users do not need to perform string decoding operations on it. Likewise, when performing user defined processing functions, the received data will also be of type `numpy.str_` directly, matching the original source data type.
|
||||
|
||||
### Contributors
|
||||
|
||||
Thanks goes to these wonderful people:
|
||||
|
||||
AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bingyaweng, BowenK, buxue, caifubi, CaoJian, caojian05, caozhou, Cathy, changzherui, chenbo116, chenfei, chengxianbin, chenhaozhe, chenjianping, chenzomi, chenzupeng, chujinjin, cj, cjh9368, Corleone, damon0626, danish, Danish, davidmc, dayschan, doitH, dong-li001, fary86, fuzhiye, Gaoxiong, GAO_HYP_XYJ, gengdongjie, Gogery, gongdaguo, gray0v0, gukecai, guoqi, gzhcv, hangq, hanhuifeng2020, Harshvardhan, He, hesham, hexia, Hoai, HuangBingjian, huangdongrun, huanghui, huangxinjing, huqi, huzhifeng, hwjiaorui, Jiabin Liu, jianghui58, Jiaqi, jin-xiulang, jinyaohui, jjfeing, John, jonyguo, JulyAi, jzg, kai00, kingfo, kingxian, kpy, kswang, liuyongqi, laiyongqiang, leonwanghui, liangchenghui, liangzelang, lichen_101010, lichenever, lihongkang, lilei, limingqi107, ling, linqingke, Lin Xh, liubuyu, liuwenhao4, liuxiao78, liuxiao93, liuyang_655, liuzhongkai, liyanliu, lizhenyu, lvchangquan, lvliang, lz, maning202007, Margaret_wangrui, mengyuanli, Ming_blue, ms_yan, panfengfeng, panyifeng, Payne, peixu_ren, Pengyongrong, qianjiahong, r1chardf1d0, riemann_penn, rmdyh, Sheng, shenwei41, simson, Simson, Su, sunsuodong, tao_yunhao, tinazhang, VectorSL, Wan, wandongdong, wangdongxu, wangmin, wangyue01, wangzhe, wanyiming, Wei, wenchunjiang, wilfChen, WilliamLian, wsc, wudenggang, wukesong, wuweikang, Xiao Tianci, Xiaoda, xiefangqi, xinyunfan, xuanyue, xuyongfei, yanghaitao, yanghaoran, YangLuo, yangruoqi713, yankai, yanzhenxiang2020, yao_yf, yepei6, yeyunpeng, Yi, yoni, yoonlee666, yuchaojie, yujianfeng, yuximiao, zengzitao, Zhang, zhanghuiyao, zhanghui_china, zhangxinfeng3, zhangyihui, zhangz0911gm, zhanyuan, zhaojichen, zhaoting, zhaozhenlong, zhengjun10, zhiqwang, zhoufeng, zhousiyi, zhouyaqiang, zhouyifengCode, Zichun, Ziyan, zjun, ZPaC, wangfengwfwf, zymaa, gerayking, shu-kun-zhang.
|
||||
|
||||
Contributions of any kind are welcome!
|
||||
|
||||
## MindSpore 1.8.1 Release Notes
|
||||
|
||||
|
@ -72,8 +188,6 @@
|
|||
- [STABLE] Add CPU support for ops.xdivy.
|
||||
- [STABLE] Add CPU support for ops.xlogy.
|
||||
|
||||
# MindSpore 1.8.0
|
||||
|
||||
## MindSpore 1.8.0 Release Notes
|
||||
|
||||
### Major Features and Improvements
|
||||
|
@ -126,7 +240,7 @@
|
|||
- [STABLE] When using the map operation for dataset objects and the parameters like: num_parallel_workers > 1 and python_multiprocessing=True, the multi-process mechanism is optimized, so that the data channel and child processes are mapped one by one, avoiding excessive file handle occupation, and closing_pool interface is also deleted.
|
||||
- [STABLE] Add a batch of Vision, Text and Audio data augmentation operations.
|
||||
- [STABLE] Fix a bug where the flat_map method of the Dataset class does not flatten the result.
|
||||
- [STABLE] Unify import paths of dataset augmentation APIs to provide more easier way to use. Refer to [latest api usages](https://www.mindspore.cn/docs/en/master/api_python/mindspore.dataset.vision.html).
|
||||
- [STABLE] Unify import paths of dataset augmentation APIs to provide more easier way to use. Refer to [latest api usages](https://www.mindspore.cn/docs/en/r1.8/api_python/mindspore.dataset.vision.html).
|
||||
|
||||
### API Change
|
||||
|
||||
|
@ -250,7 +364,15 @@ For examples:
|
|||
|
||||
The API pages are aggregated to <https://www.mindspore.cn/docs/en/master/api_python/mindspore.html>.
|
||||
|
||||
## MindSpore Lite
|
||||
### Contributors
|
||||
|
||||
Thanks goes to these wonderful people:
|
||||
|
||||
AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bingyaweng, BowenK, buxue, caifubi, CaoJian, caojian05, caozhou, Cathy, changzherui, chenbo116, chenfei, chengxianbin, chenhaozhe, chenjianping, chenzomi, chenzupeng, chujinjin, cj, cjh9368, Corleone, damon0626, danish, Danish, davidmc, dayschan, doitH, dong-li001, fary86, fuzhiye, Gaoxiong, GAO_HYP_XYJ, gengdongjie, Gogery, gongdaguo, gray0v0, gukecai, guoqi, gzhcv, hangq, hanhuifeng2020, Harshvardhan, He, heleiwang, hesham, hexia, Hoai, HuangBingjian, huangdongrun, huanghui, huangxinjing, huqi, huzhifeng, hwjiaorui, Jiabin Liu, jianghui58, Jiaqi, jin-xiulang, jinyaohui, jjfeing, John, jonyguo, JulyAi, jzg, kai00, kingfo, kingxian, kpy, kswang, liuyongqi, laiyongqiang, leonwanghui, liangchenghui, liangzelang, lichen_101010, lichenever, lihongkang, lilei, limingqi107, ling, linqingke, Lin Xh, liubuyu, liuwenhao4, liuxiao78, liuxiao93, liuyang_655, liuzhongkai, Lixia, lixian, liyanliu, liyong, lizhenyu, luopengting, lvchangquan, lvliang, lz, maning202007, Margaret_wangrui, mengyuanli, Ming_blue, ms_yan, ougongchang, panfengfeng, panyifeng, Payne, Peilin, peixu_ren, Pengyongrong, qianlong, qianjiahong, r1chardf1d0, riemann_penn, rmdyh, Sheng, shenwei41, simson, Simson, Su, sunsuodong, tao_yunhao, tinazhang, VectorSL, , Wan, wandongdong, wangdongxu, wangmin, wangyue01, wangzhe, wanyiming, Wei, wenchunjiang, wilfChen, WilliamLian, wsc, wudenggang, wukesong, wuweikang, wuxuejian, Xiao Tianci, Xiaoda, xiefangqi, xinyunfan, xuanyue, xuyongfei, yanghaitao, yanghaitao1, yanghaoran, YangLuo, yangruoqi713, yankai, yanzhenxiang2020, yao_yf, yepei6, yeyunpeng, Yi, yoni, yoonlee666, yuchaojie, yujianfeng, yuximiao, zengzitao, Zhang, zhanghuiyao, zhanghui_china, zhangxinfeng3, zhangyihui, zhangz0911gm, zhanke, zhanyuan, zhaodezan, zhaojichen, zhaoting, zhaozhenlong, zhengjun10, zhiqwang, zhoufeng, zhousiyi, zhouyaqiang, zhouyifengCode, Zichun, Ziyan, zjun, ZPaC, wangfengwfwf, zymaa, gerayking, shu-kun-zhang.
|
||||
|
||||
Contributions of any kind are welcome!
|
||||
|
||||
## MindSpore Lite 1.8.0 Release Notes
|
||||
|
||||
### Major Features and Improvements
|
||||
|
||||
|
@ -263,14 +385,6 @@ The API pages are aggregated to <https://www.mindspore.cn/docs/en/master/api_pyt
|
|||
|
||||
- [STABLE] Support perlayer quantization, and built-in CLE to optimize perlayer quantization accuracy.
|
||||
|
||||
### Contributors
|
||||
|
||||
Thanks goes to these wonderful people:
|
||||
|
||||
AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bingyaweng, BowenK, buxue, caifubi, CaoJian, caojian05, caozhou, Cathy, changzherui, chenbo116, chenfei, chengxianbin, chenhaozhe, chenjianping, chenzomi, chenzupeng, chujinjin, cj, cjh9368, Corleone, damon0626, danish, Danish, davidmc, dayschan, doitH, dong-li001, fary86, fuzhiye, Gaoxiong, GAO_HYP_XYJ, gengdongjie, Gogery, gongdaguo, gray0v0, gukecai, guoqi, gzhcv, hangq, hanhuifeng2020, Harshvardhan, He, heleiwang, hesham, hexia, Hoai, HuangBingjian, huangdongrun, huanghui, huangxinjing, huqi, huzhifeng, hwjiaorui, Jiabin Liu, jianghui58, Jiaqi, jin-xiulang, jinyaohui, jjfeing, John, jonyguo, JulyAi, jzg, kai00, kingfo, kingxian, kpy, kswang, liuyongqi, laiyongqiang, leonwanghui, liangchenghui, liangzelang, lichen_101010, lichenever, lihongkang, lilei, limingqi107, ling, linqingke, Lin Xh, liubuyu, liuwenhao4, liuxiao78, liuxiao93, liuyang_655, liuzhongkai, Lixia, lixian, liyanliu, liyong, lizhenyu, luopengting, lvchangquan, lvliang, lz, maning202007, Margaret_wangrui, mengyuanli, Ming_blue, ms_yan, ougongchang, panfengfeng, panyifeng, Payne, Peilin, peixu_ren, Pengyongrong, qianlong, qianjiahong, r1chardf1d0, riemann_penn, rmdyh, Sheng, shenwei41, simson, Simson, Su, sunsuodong, tao_yunhao, tinazhang, VectorSL, , Wan, wandongdong, wangdongxu, wangmin, wangyue01, wangzhe, wanyiming, Wei, wenchunjiang, wilfChen, WilliamLian, wsc, wudenggang, wukesong, wuweikang, wuxuejian, Xiao Tianci, Xiaoda, xiefangqi, xinyunfan, xuanyue, xuyongfei, yanghaitao, yanghaitao1, yanghaoran, YangLuo, yangruoqi713, yankai, yanzhenxiang2020, yao_yf, yepei6, yeyunpeng, Yi, yoni, yoonlee666, yuchaojie, yujianfeng, yuximiao, zengzitao, Zhang, zhanghuiyao, zhanghui_china, zhangxinfeng3, zhangyihui, zhangz0911gm, zhanke, zhanyuan, zhaodezan, zhaojichen, zhaoting, zhaozhenlong, zhengjun10, zhiqwang, zhoufeng, zhousiyi, zhouyaqiang, zhouyifengCode, Zichun, Ziyan, zjun, ZPaC, wangfengwfwf, zymaa, gerayking, shu-kun-zhang.
|
||||
|
||||
Contributions of any kind are welcome!
|
||||
|
||||
## MindSpore 1.7.0 Release Notes
|
||||
|
||||
### Major Features and Improvements
|
||||
|
@ -339,7 +453,15 @@ Contributions of any kind are welcome!
|
|||
- Deprecate `mindspore.SparseTensor` and use `mindspore.COOTensor` instead. ([!28505](https://gitee.com/mindspore/mindspore/pulls/28505))
|
||||
- Add Tensor init arg `internal` for internal use.
|
||||
|
||||
## MindSpore Lite
|
||||
### Contributors
|
||||
|
||||
Thanks goes to these wonderful people:
|
||||
|
||||
AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bingyaweng, BowenK, buxue, caifubi, CaoJian, caojian05, caozhou, Cathy, changzherui, chenbo116, chenfei, chengxianbin, chenhaozhe, chenjianping, chenzomi, chenzupeng, chujinjin, cj, cjh9368, Corleone, damon0626, danish, Danish, davidmc, dayschan, doitH, dong-li001, fary86, fuzhiye, Gaoxiong, GAO_HYP_XYJ, gengdongjie, Gogery, gongdaguo, gray0v0, gukecai, guoqi, gzhcv, hangq, hanhuifeng2020, Harshvardhan, He, heleiwang, hesham, hexia, Hoai, HuangBingjian, huangdongrun, huanghui, huangxinjing, huqi, huzhifeng, hwjiaorui, Jiabin Liu, jianghui58, Jiaqi, jin-xiulang, jinyaohui, jjfeing, John, jonyguo, JulyAi, jzg, kai00, kingfo, kingxian, kpy, kswang, liuyongqi, laiyongqiang, leonwanghui, liangchenghui, liangzelang, lichen_101010, lichenever, lihongkang, lilei, limingqi107, ling, linqingke, Lin Xh, liubuyu, liuwenhao4, liuxiao78, liuxiao93, liuyang_655, liuzhongkai, Lixia, lixian, liyanliu, liyong, lizhenyu, luopengting, lvchangquan, lvliang, lz, maning202007, Margaret_wangrui, mengyuanli, Ming_blue, ms_yan, ougongchang, panfengfeng, panyifeng, Payne, Peilin, peixu_ren, Pengyongrong, qianlong, qianjiahong, r1chardf1d0, riemann_penn, rmdyh, Sheng, shenwei41, simson, Simson, Su, sunsuodong, tao_yunhao, tinazhang, VectorSL, , Wan, wandongdong, wangdongxu, wangmin, wangyue01, wangzhe, wanyiming, Wei, wenchunjiang, wilfChen, WilliamLian, wsc, wudenggang, wukesong, wuweikang, wuxuejian, Xiao Tianci, Xiaoda, xiefangqi, xinyunfan, xuanyue, xuyongfei, yanghaitao, yanghaitao1, yanghaoran, YangLuo, yangruoqi713, yankai, yanzhenxiang2020, yao_yf, yepei6, yeyunpeng, Yi, yoni, yoonlee666, yuchaojie, yujianfeng, yuximiao, zengzitao, Zhang, zhanghuiyao, zhanghui_china, zhangxinfeng3, zhangyihui, zhangz0911gm, zhanke, zhanyuan, zhaodezan, zhaojichen, zhaoting, zhaozhenlong, zhengjun10, zhiqwang, zhoufeng, zhousiyi, zhouyaqiang, zhouyifengCode, Zichun, Ziyan, zjun, ZPaC, wangfengwfwf, zymaa, gerayking.
|
||||
|
||||
Contributions of any kind are welcome!
|
||||
|
||||
## MindSpore Lite 1.7.0 Release Notes
|
||||
|
||||
### Major Features and Improvements
|
||||
|
||||
|
@ -348,14 +470,6 @@ Contributions of any kind are welcome!
|
|||
- [STABLE] Support post quantization to run dynamic quantization algorithm.
|
||||
- [BETA] Support post quantized model to run on NVIDIA GPU.
|
||||
|
||||
## Contributors
|
||||
|
||||
Thanks goes to these wonderful people:
|
||||
|
||||
AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bingyaweng, BowenK, buxue, caifubi, CaoJian, caojian05, caozhou, Cathy, changzherui, chenbo116, chenfei, chengxianbin, chenhaozhe, chenjianping, chenzomi, chenzupeng, chujinjin, cj, cjh9368, Corleone, damon0626, danish, Danish, davidmc, dayschan, doitH, dong-li001, fary86, fuzhiye, Gaoxiong, GAO_HYP_XYJ, gengdongjie, Gogery, gongdaguo, gray0v0, gukecai, guoqi, gzhcv, hangq, hanhuifeng2020, Harshvardhan, He, heleiwang, hesham, hexia, Hoai, HuangBingjian, huangdongrun, huanghui, huangxinjing, huqi, huzhifeng, hwjiaorui, Jiabin Liu, jianghui58, Jiaqi, jin-xiulang, jinyaohui, jjfeing, John, jonyguo, JulyAi, jzg, kai00, kingfo, kingxian, kpy, kswang, liuyongqi, laiyongqiang, leonwanghui, liangchenghui, liangzelang, lichen_101010, lichenever, lihongkang, lilei, limingqi107, ling, linqingke, Lin Xh, liubuyu, liuwenhao4, liuxiao78, liuxiao93, liuyang_655, liuzhongkai, Lixia, lixian, liyanliu, liyong, lizhenyu, luopengting, lvchangquan, lvliang, lz, maning202007, Margaret_wangrui, mengyuanli, Ming_blue, ms_yan, ougongchang, panfengfeng, panyifeng, Payne, Peilin, peixu_ren, Pengyongrong, qianlong, qianjiahong, r1chardf1d0, riemann_penn, rmdyh, Sheng, shenwei41, simson, Simson, Su, sunsuodong, tao_yunhao, tinazhang, VectorSL, , Wan, wandongdong, wangdongxu, wangmin, wangyue01, wangzhe, wanyiming, Wei, wenchunjiang, wilfChen, WilliamLian, wsc, wudenggang, wukesong, wuweikang, wuxuejian, Xiao Tianci, Xiaoda, xiefangqi, xinyunfan, xuanyue, xuyongfei, yanghaitao, yanghaitao1, yanghaoran, YangLuo, yangruoqi713, yankai, yanzhenxiang2020, yao_yf, yepei6, yeyunpeng, Yi, yoni, yoonlee666, yuchaojie, yujianfeng, yuximiao, zengzitao, Zhang, zhanghuiyao, zhanghui_china, zhangxinfeng3, zhangyihui, zhangz0911gm, zhanke, zhanyuan, zhaodezan, zhaojichen, zhaoting, zhaozhenlong, zhengjun10, zhiqwang, zhoufeng, zhousiyi, zhouyaqiang, zhouyifengCode, Zichun, Ziyan, zjun, ZPaC, wangfengwfwf, zymaa, gerayking.
|
||||
|
||||
Contributions of any kind are welcome!
|
||||
|
||||
# MindSpore 1.6.0
|
||||
|
||||
## MindSpore 1.6.0 Release Notes
|
||||
|
|
158
RELEASE_CN.md
158
RELEASE_CN.md
|
@ -2,7 +2,123 @@
|
|||
|
||||
[View English](./RELEASE.md)
|
||||
|
||||
# MindSpore 1.8.1
|
||||
## MindSpore 1.10.1 Release Notes
|
||||
|
||||
### 问题修复
|
||||
|
||||
- 修复logsumexp防溢出处理中未考虑指定axis的问题
|
||||
- 修复proto文件的编译依赖问题
|
||||
- 修复print算子打印结果不正常的问题
|
||||
- 修复equal算子越界问题
|
||||
- 修复函数被@jit修饰后,导致的cell_id解析不正确的问题
|
||||
- 修复GNN场景数据类型校验错误
|
||||
- 修复Dataset map多进程退化成线程的问题
|
||||
|
||||
### 贡献者
|
||||
|
||||
感谢以下人员做出的贡献:
|
||||
|
||||
archer2049, caifubi, chenfei_mindspore, gaoshuanglong, Greatpan, guozhijian, huoxinyou, Kxiong, lanzhineng, lijunbin, liubuyu, liuchuting, luochao60, lyqlola, nomindcarry, TuDouNi, xiaotianci, xupan, yangshuo, yefeng, YingtongHu, yuchaojie, zhoufeng, ZPaC, 刘勇琪, 吕昱峰, 王禹程, 于振华.
|
||||
|
||||
欢迎以任何形式对项目提供贡献!
|
||||
|
||||
## MindSpore 1.10.0 Release Notes
|
||||
|
||||
### 主要特性和增强
|
||||
|
||||
#### DataSet
|
||||
|
||||
- [STABLE]下沉模式超时等待时间调整,默认调整到600s,以解决数据下沉模式时因环境资源竞争、计算量大等因素容易导致GetNext算子等待超时的问题。
|
||||
|
||||
### Bug fixes
|
||||
|
||||
- 修复AMP中部分Primitive算子无法在图模式下实例化导致接口不可用的问题。
|
||||
- 修复昇腾平台算力切分场景下LSTM网络中DynamicRNN算子执行失败的问题。
|
||||
- 修复mobilenet, fasterrcnn, yolo等网络单卡训练脚本DEVICE_ID在启动脚本中写死的问题。
|
||||
|
||||
### 贡献者
|
||||
|
||||
感谢以下人员做出的贡献:
|
||||
|
||||
AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bingyaweng, BowenK, buxue, caifubi, CaoJian, caojian05, caozhou, Cathy, changzherui, chenbo116, chenfei, chengxianbin, chenhaozhe, chenjianping, chenzomi, chenzupeng, chujinjin, cj, cjh9368, Corleone, damon0626, danish, Danish, davidmc, dayschan, doitH, dong-li001, fary86, fuzhiye, Gaoxiong, GAO_HYP_XYJ, gengdongjie, Gogery, gongdaguo, gray0v0, gukecai, guoqi, gzhcv, hangq, hanhuifeng2020, Harshvardhan, He, heleiwang, hesham, hexia, Hoai, HuangBingjian, huangdongrun, huanghui, huangxinjing, huqi, huzhifeng, hwjiaorui, Jiabin Liu, jianghui58, Jiaqi, jin-xiulang, jinyaohui, jjfeing, John, jonyguo, JulyAi, jzg, kai00, kingfo, kingxian, kpy, kswang, liuyongqi, laiyongqiang, leonwanghui, liangchenghui, liangzelang, lichen_101010, lichenever, lihongkang, lilei, limingqi107, ling, linqingke, Lin Xh, liubuyu, liuwenhao4, liuxiao78, liuxiao93, liuyang_655, liuzhongkai, Lixia, lixian, liyanliu, liyong, lizhenyu, luopengting, lvchangquan, lvliang, lz, maning202007, Margaret_wangrui, mengyuanli, Ming_blue, ms_yan, ougongchang, panfengfeng, panyifeng, Payne, Peilin, peixu_ren, Pengyongrong, qianlong, qianjiahong, r1chardf1d0, riemann_penn, rmdyh, Sheng, shenwei41, simson, Simson, Su, sunsuodong, tao_yunhao, tinazhang, VectorSL, , Wan, wandongdong, wangdongxu, wangmin, wangyue01, wangzhe, wanyiming, Wei, wenchunjiang, wilfChen, WilliamLian, wsc, wudenggang, wukesong, wuweikang, wuxuejian, Xiao Tianci, Xiaoda, xiefangqi, xinyunfan, xuanyue, xuyongfei, yanghaitao, yanghaitao1, yanghaoran, YangLuo, yangruoqi713, yankai, yanzhenxiang2020, yao_yf, yepei6, yeyunpeng, Yi, yoni, yoonlee666, yuchaojie, yujianfeng, yuximiao, zengzitao, Zhang, zhanghuiyao, zhanghui_china, zhangxinfeng3, zhangyihui, zhangz0911gm, zhanke, zhanyuan, zhaodezan, zhaojichen, zhaoting, zhaozhenlong, zhengjun10, zhiqwang, zhoufeng, zhousiyi, zhouyaqiang, zhouyifengCode, Zichun, Ziyan, zjun, ZPaC, wangfengwfwf, zymaa, gerayking, shu-kun-zhang.
|
||||
|
||||
欢迎以任何形式对项目提供贡献!
|
||||
|
||||
## MindSpore Lite 1.10.0 Release Notes
|
||||
|
||||
### Bug fixes
|
||||
|
||||
- 修复Arithmetic类CPU算子动态shape场景下可能的计算精度问题。
|
||||
- 修复Deconv int8量化算子重量化写入地址错误问题。
|
||||
|
||||
## MindSpore 1.9.0 Release Notes
|
||||
|
||||
### 主要特性和增强
|
||||
|
||||
#### FrontEnd
|
||||
|
||||
- [STABLE] 新增面向对象+函数式融合编程范式,提供 `mindspore.amp.LossScaler` 、 `mindspore.amp.DynamicLossScaler` 、 `mindspore.amp.StaticLossScaler` 、 `mindspore.amp.auto_mixed_precision` 、 `mindspore.amp.all_finite` 等融合编程范式下的混合精度接口。
|
||||
|
||||
### API变更
|
||||
|
||||
#### 算子
|
||||
|
||||
- [STABLE] `nn.AdaptiveAvgPool3d` 新增nn接口。
|
||||
- [STABLE] `ops.adaptive_avg_pool3d` 新增functional接口。
|
||||
- [STABLE] `ops.addcdiv` 新增functional接口。
|
||||
- [STABLE] `ops.addcmul` 新增functional接口。
|
||||
- [STABLE] `ops.approximate_equal` 新增GPU、CPU支持。
|
||||
- [STABLE] `ops.atanh` 新增GPU支持。
|
||||
- [STABLE] `ops.bessel_i0` 新增GPU支持。
|
||||
- [STABLE] `ops.bessel_i0e` 新增Ascend支持。
|
||||
- [STABLE] `ops.bessel_i1` 新增GPU支持。
|
||||
- [STABLE] `ops.bessel_i1e` 新增Ascend、GPU支持。
|
||||
- [STABLE] `ops.bessel_j0` 新增GPU支持。
|
||||
- [STABLE] `ops.bessel_j1` 新增GPU支持。
|
||||
- [STABLE] `ops.bessel_k0` 新增GPU支持。
|
||||
- [STABLE] `ops.bessel_k0e` 新增GPU支持。
|
||||
- [STABLE] `ops.bessel_k1` 新增GPU支持。
|
||||
- [STABLE] `ops.bessel_k1e` 新增GPU支持。
|
||||
- [STABLE] `ops.bessel_y0` 新增GPU支持。
|
||||
- [STABLE] `ops.bessel_y1` 新增GPU支持。
|
||||
- [STABLE] `ops.bias_add` 新增functional接口。
|
||||
- [STABLE] `ops.bitwise_and` 新增GPU支持。
|
||||
- [STABLE] `ops.bitwise_or` 新增GPU支持。
|
||||
- [STABLE] `ops.bitwise_xor` 新增GPU支持。
|
||||
- [STABLE] `ops.grid_sample` 新增Ascend支持。
|
||||
- [STABLE] `ops.inplace_update` 新增CPU支持。
|
||||
- [STABLE] `ops.isclose` 新增Ascend、GPU支持。
|
||||
- [STABLE] `ops.isnan` 新增Ascend支持。
|
||||
- [STABLE] `ops.lerp` 新增GPU支持。
|
||||
- [STABLE] `ops.random_poisson` 新增functional接口。
|
||||
- [STABLE] `ops.reverse_sequence` 新增functional接口。
|
||||
- [STABLE] `ops.scatter_mul` 新增GPU支持。
|
||||
- [STABLE] `ops.scatter_nd_max` 新增functional接口。
|
||||
- [STABLE] `ops.scatter_nd_min` 新增functional接口。
|
||||
- [STABLE] `ops.SparseToDense` 新增GPU支持。
|
||||
- [STABLE] `ops.square` 新增functional接口。
|
||||
- [STABLE] `ops.standard_laplace` 新增GPU支持。
|
||||
- [STABLE] `ops.std` 新增functional接口。
|
||||
- [STABLE] `ops.trunc` 新增Ascend、GPU支持。
|
||||
- [STABLE] `ops.unsorted_segment_sum` 新增functional接口。
|
||||
- [STABLE] `ops.xdivy` 新增functional接口。
|
||||
- [STABLE] `ops.xlogy` 新增GPU支持。
|
||||
- `ops.poisson` 接口废弃使用,对应新接口为 `ops.random_poisson` 。
|
||||
- `ops.SparseApplyAdagrad` 接口废弃使用,可使用 `ops.SparseApplyAdagradV2` 接口替代。
|
||||
|
||||
### Bug fixes
|
||||
|
||||
- [BUGFIX] 修改混合精度O2 level的判断逻辑,在原来屏蔽 `BatchNorm1d` 、 `BatchNorm2d` 算子的基础上,添加另外两个屏蔽算子`BatchNorm3d`和`LayerNorm`,这4个算子依然用float32数据类型计算。
|
||||
|
||||
- [BUGFIX] Dataset处理字符串类型数据时,若调用`create_dict_iterator`或`create_tuple_iterator`接口时指定了`output_numpy=True`,获取到的数据会是`numpy.bytes_`类型。修复此问题后接口会直接返回`numpy.str_`类型数据,用户无需再对其进行字符串解码操作。同样,在使用自定义数据处理函数时,接收到的数据也将直接是`numpy.str_`类型,与原始数据类型相匹配。
|
||||
|
||||
### 贡献者
|
||||
|
||||
感谢以下人员做出的贡献:
|
||||
|
||||
AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bingyaweng, BowenK, buxue, caifubi, CaoJian, caojian05, caozhou, Cathy, changzherui, chenbo116, chenfei, chengxianbin, chenhaozhe, chenjianping, chenzomi, chenzupeng, chujinjin, cj, cjh9368, Corleone, damon0626, danish, Danish, davidmc, dayschan, doitH, dong-li001, fary86, fuzhiye, Gaoxiong, GAO_HYP_XYJ, gengdongjie, Gogery, gongdaguo, gray0v0, gukecai, guoqi, gzhcv, hangq, hanhuifeng2020, Harshvardhan, He, hesham, hexia, Hoai, HuangBingjian, huangdongrun, huanghui, huangxinjing, huqi, huzhifeng, hwjiaorui, Jiabin Liu, jianghui58, Jiaqi, jin-xiulang, jinyaohui, jjfeing, John, jonyguo, JulyAi, jzg, kai00, kingfo, kingxian, kpy, kswang, liuyongqi, laiyongqiang, leonwanghui, liangchenghui, liangzelang, lichen_101010, lichenever, lihongkang, lilei, limingqi107, ling, linqingke, Lin Xh, liubuyu, liuwenhao4, liuxiao78, liuxiao93, liuyang_655, liuzhongkai, liyanliu, lizhenyu, lvchangquan, lvliang, lz, maning202007, Margaret_wangrui, mengyuanli, Ming_blue, ms_yan, panfengfeng, panyifeng, Payne, peixu_ren, Pengyongrong, qianjiahong, r1chardf1d0, riemann_penn, rmdyh, Sheng, shenwei41, simson, Simson, Su, sunsuodong, tao_yunhao, tinazhang, VectorSL, Wan, wandongdong, wangdongxu, wangmin, wangyue01, wangzhe, wanyiming, Wei, wenchunjiang, wilfChen, WilliamLian, wsc, wudenggang, wukesong, wuweikang, Xiao Tianci, Xiaoda, xiefangqi, xinyunfan, xuanyue, xuyongfei, yanghaitao, yanghaoran, YangLuo, yangruoqi713, yankai, yanzhenxiang2020, yao_yf, yepei6, yeyunpeng, Yi, yoni, yoonlee666, yuchaojie, yujianfeng, yuximiao, zengzitao, Zhang, zhanghuiyao, zhanghui_china, zhangxinfeng3, zhangyihui, zhangz0911gm, zhanyuan, zhaojichen, zhaoting, zhaozhenlong, zhengjun10, zhiqwang, zhoufeng, zhousiyi, zhouyaqiang, zhouyifengCode, Zichun, Ziyan, zjun, ZPaC, wangfengwfwf, zymaa, gerayking, shu-kun-zhang.
|
||||
|
||||
欢迎以任何形式对项目提供贡献!
|
||||
|
||||
## MindSpore 1.8.1 Release Notes
|
||||
|
||||
|
@ -72,8 +188,6 @@
|
|||
- [STABLE] ops.xdivy 新增CPU支持。
|
||||
- [STABLE] ops.xlogy 新增CPU支持。
|
||||
|
||||
# MindSpore 1.8.0
|
||||
|
||||
## MindSpore 1.8.0 Release Notes
|
||||
|
||||
### 主要特性和增强
|
||||
|
@ -126,7 +240,7 @@
|
|||
- [STABLE] 对于数据集对象使用map操作时,同时num_parallel_workers>1并且python_multiprocessing=True时,进行了多进程的机制优化,使得数据通道与子进程一一映射,避免了过多的文件句柄占用,同时close_pool这个接口也被删除。
|
||||
- [STABLE] 新增一批Vision、Text和Audio类数据增强操作。
|
||||
- [STABLE] 修复数据集类的flat_map方法未将结果展平的错误。
|
||||
- [STABLE] 统一数据集增强API的导入路径,提供更简单的使用方法,请参阅[最新的API用法](https://www.mindspore.cn/docs/zh-CN/master/api_python/mindspore.dataset.vision.html)。
|
||||
- [STABLE] 统一数据集增强API的导入路径,提供更简单的使用方法,请参阅[最新的API用法](https://www.mindspore.cn/docs/zh-CN/r1.8/api_python/mindspore.dataset.vision.html)。
|
||||
|
||||
### API变更
|
||||
|
||||
|
@ -250,7 +364,15 @@ mindspore.context、mindspore.parallel、mindspore.profiler、mindspore.train模
|
|||
|
||||
API页面统一汇总至:<https://www.mindspore.cn/docs/zh-CN/master/api_python/mindspore.html>。
|
||||
|
||||
## MindSpore Lite
|
||||
### 贡献者
|
||||
|
||||
感谢以下人员做出的贡献:
|
||||
|
||||
AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bingyaweng, BowenK, buxue, caifubi, CaoJian, caojian05, caozhou, Cathy, changzherui, chenbo116, chenfei, chengxianbin, chenhaozhe, chenjianping, chenzomi, chenzupeng, chujinjin, cj, cjh9368, Corleone, damon0626, danish, Danish, davidmc, dayschan, doitH, dong-li001, fary86, fuzhiye, Gaoxiong, GAO_HYP_XYJ, gengdongjie, Gogery, gongdaguo, gray0v0, gukecai, guoqi, gzhcv, hangq, hanhuifeng2020, Harshvardhan, He, heleiwang, hesham, hexia, Hoai, HuangBingjian, huangdongrun, huanghui, huangxinjing, huqi, huzhifeng, hwjiaorui, Jiabin Liu, jianghui58, Jiaqi, jin-xiulang, jinyaohui, jjfeing, John, jonyguo, JulyAi, jzg, kai00, kingfo, kingxian, kpy, kswang, liuyongqi, laiyongqiang, leonwanghui, liangchenghui, liangzelang, lichen_101010, lichenever, lihongkang, lilei, limingqi107, ling, linqingke, Lin Xh, liubuyu, liuwenhao4, liuxiao78, liuxiao93, liuyang_655, liuzhongkai, Lixia, lixian, liyanliu, liyong, lizhenyu, luopengting, lvchangquan, lvliang, lz, maning202007, Margaret_wangrui, mengyuanli, Ming_blue, ms_yan, ougongchang, panfengfeng, panyifeng, Payne, Peilin, peixu_ren, Pengyongrong, qianlong, qianjiahong, r1chardf1d0, riemann_penn, rmdyh, Sheng, shenwei41, simson, Simson, Su, sunsuodong, tao_yunhao, tinazhang, VectorSL, , Wan, wandongdong, wangdongxu, wangmin, wangyue01, wangzhe, wanyiming, Wei, wenchunjiang, wilfChen, WilliamLian, wsc, wudenggang, wukesong, wuweikang, wuxuejian, Xiao Tianci, Xiaoda, xiefangqi, xinyunfan, xuanyue, xuyongfei, yanghaitao, yanghaitao1, yanghaoran, YangLuo, yangruoqi713, yankai, yanzhenxiang2020, yao_yf, yepei6, yeyunpeng, Yi, yoni, yoonlee666, yuchaojie, yujianfeng, yuximiao, zengzitao, Zhang, zhanghuiyao, zhanghui_china, zhangxinfeng3, zhangyihui, zhangz0911gm, zhanke, zhanyuan, zhaodezan, zhaojichen, zhaoting, zhaozhenlong, zhengjun10, zhiqwang, zhoufeng, zhousiyi, zhouyaqiang, zhouyifengCode, Zichun, Ziyan, zjun, ZPaC, wangfengwfwf, zymaa, gerayking, shu-kun-zhang.
|
||||
|
||||
欢迎以任何形式对项目提供贡献!
|
||||
|
||||
## MindSpore Lite 1.8.0 Release Notes
|
||||
|
||||
### 主要特性和增强
|
||||
|
||||
|
@ -263,14 +385,6 @@ API页面统一汇总至:<https://www.mindspore.cn/docs/zh-CN/master/api_pytho
|
|||
|
||||
- [STABLE] 后量化支持PerLayer量化,同时内置CLE算法优化精度。
|
||||
|
||||
### 贡献者
|
||||
|
||||
感谢以下人员做出的贡献:
|
||||
|
||||
AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bingyaweng, BowenK, buxue, caifubi, CaoJian, caojian05, caozhou, Cathy, changzherui, chenbo116, chenfei, chengxianbin, chenhaozhe, chenjianping, chenzomi, chenzupeng, chujinjin, cj, cjh9368, Corleone, damon0626, danish, Danish, davidmc, dayschan, doitH, dong-li001, fary86, fuzhiye, Gaoxiong, GAO_HYP_XYJ, gengdongjie, Gogery, gongdaguo, gray0v0, gukecai, guoqi, gzhcv, hangq, hanhuifeng2020, Harshvardhan, He, heleiwang, hesham, hexia, Hoai, HuangBingjian, huangdongrun, huanghui, huangxinjing, huqi, huzhifeng, hwjiaorui, Jiabin Liu, jianghui58, Jiaqi, jin-xiulang, jinyaohui, jjfeing, John, jonyguo, JulyAi, jzg, kai00, kingfo, kingxian, kpy, kswang, liuyongqi, laiyongqiang, leonwanghui, liangchenghui, liangzelang, lichen_101010, lichenever, lihongkang, lilei, limingqi107, ling, linqingke, Lin Xh, liubuyu, liuwenhao4, liuxiao78, liuxiao93, liuyang_655, liuzhongkai, Lixia, lixian, liyanliu, liyong, lizhenyu, luopengting, lvchangquan, lvliang, lz, maning202007, Margaret_wangrui, mengyuanli, Ming_blue, ms_yan, ougongchang, panfengfeng, panyifeng, Payne, Peilin, peixu_ren, Pengyongrong, qianlong, qianjiahong, r1chardf1d0, riemann_penn, rmdyh, Sheng, shenwei41, simson, Simson, Su, sunsuodong, tao_yunhao, tinazhang, VectorSL, , Wan, wandongdong, wangdongxu, wangmin, wangyue01, wangzhe, wanyiming, Wei, wenchunjiang, wilfChen, WilliamLian, wsc, wudenggang, wukesong, wuweikang, wuxuejian, Xiao Tianci, Xiaoda, xiefangqi, xinyunfan, xuanyue, xuyongfei, yanghaitao, yanghaitao1, yanghaoran, YangLuo, yangruoqi713, yankai, yanzhenxiang2020, yao_yf, yepei6, yeyunpeng, Yi, yoni, yoonlee666, yuchaojie, yujianfeng, yuximiao, zengzitao, Zhang, zhanghuiyao, zhanghui_china, zhangxinfeng3, zhangyihui, zhangz0911gm, zhanke, zhanyuan, zhaodezan, zhaojichen, zhaoting, zhaozhenlong, zhengjun10, zhiqwang, zhoufeng, zhousiyi, zhouyaqiang, zhouyifengCode, Zichun, Ziyan, zjun, ZPaC, wangfengwfwf, zymaa, gerayking, shu-kun-zhang.
|
||||
|
||||
欢迎以任何形式对项目提供贡献!
|
||||
|
||||
## MindSpore 1.7.0 Release Notes
|
||||
|
||||
### 主要特性和增强
|
||||
|
@ -339,7 +453,15 @@ AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bing
|
|||
- `mindspore.SparseTensor`接口废弃使用,对应新接口为`mindspore.COOTensor`。 ([!28505](https://gitee.com/mindspore/mindspore/pulls/28505))
|
||||
- Tensor新增一个入参`internal`,作为框架内部使用。
|
||||
|
||||
## MindSpore Lite
|
||||
### 贡献者
|
||||
|
||||
感谢以下人员做出的贡献:
|
||||
|
||||
AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bingyaweng, BowenK, buxue, caifubi, CaoJian, caojian05, caozhou, Cathy, changzherui, chenbo116, chenfei, chengxianbin, chenhaozhe, chenjianping, chenzomi, chenzupeng, chujinjin, cj, cjh9368, Corleone, damon0626, danish, Danish, davidmc, dayschan, doitH, dong-li001, fary86, fuzhiye, Gaoxiong, GAO_HYP_XYJ, gengdongjie, Gogery, gongdaguo, gray0v0, gukecai, guoqi, gzhcv, hangq, hanhuifeng2020, Harshvardhan, He, heleiwang, hesham, hexia, Hoai, HuangBingjian, huangdongrun, huanghui, huangxinjing, huqi, huzhifeng, hwjiaorui, Jiabin Liu, jianghui58, Jiaqi, jin-xiulang, jinyaohui, jjfeing, John, jonyguo, JulyAi, jzg, kai00, kingfo, kingxian, kpy, kswang, liuyongqi, laiyongqiang, leonwanghui, liangchenghui, liangzelang, lichen_101010, lichenever, lihongkang, lilei, limingqi107, ling, linqingke, Lin Xh, liubuyu, liuwenhao4, liuxiao78, liuxiao93, liuyang_655, liuzhongkai, Lixia, lixian, liyanliu, liyong, lizhenyu, luopengting, lvchangquan, lvliang, lz, maning202007, Margaret_wangrui, mengyuanli, Ming_blue, ms_yan, ougongchang, panfengfeng, panyifeng, Payne, Peilin, peixu_ren, Pengyongrong, qianlong, qianjiahong, r1chardf1d0, riemann_penn, rmdyh, Sheng, shenwei41, simson, Simson, Su, sunsuodong, tao_yunhao, tinazhang, VectorSL, , Wan, wandongdong, wangdongxu, wangmin, wangyue01, wangzhe, wanyiming, Wei, wenchunjiang, wilfChen, WilliamLian, wsc, wudenggang, wukesong, wuweikang, wuxuejian, Xiao Tianci, Xiaoda, xiefangqi, xinyunfan, xuanyue, xuyongfei, yanghaitao, yanghaitao1, yanghaoran, YangLuo, yangruoqi713, yankai, yanzhenxiang2020, yao_yf, yepei6, yeyunpeng, Yi, yoni, yoonlee666, yuchaojie, yujianfeng, yuximiao, zengzitao, Zhang, zhanghuiyao, zhanghui_china, zhangxinfeng3, zhangyihui, zhangz0911gm, zhanke, zhanyuan, zhaodezan, zhaojichen, zhaoting, zhaozhenlong, zhengjun10, zhiqwang, zhoufeng, zhousiyi, zhouyaqiang, zhouyifengCode, Zichun, Ziyan, zjun, ZPaC, wangfengwfwf, zymaa, gerayking.
|
||||
|
||||
欢迎以任何形式对项目提供贡献!
|
||||
|
||||
## MindSpore Lite 1.7.0 Release Notes
|
||||
|
||||
### 主要特性和增强
|
||||
|
||||
|
@ -347,11 +469,3 @@ AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bing
|
|||
|
||||
- [STABLE] 后量化支持动态量化算法。
|
||||
- [BETA] 后量化模型支持在英伟达GPU上执行推理。
|
||||
|
||||
## 贡献者
|
||||
|
||||
感谢以下人员做出的贡献:
|
||||
|
||||
AGroupofProbiotocs, anzhengqi, askmiao, baihuawei, baiyangfan, bai-yangfan, bingyaweng, BowenK, buxue, caifubi, CaoJian, caojian05, caozhou, Cathy, changzherui, chenbo116, chenfei, chengxianbin, chenhaozhe, chenjianping, chenzomi, chenzupeng, chujinjin, cj, cjh9368, Corleone, damon0626, danish, Danish, davidmc, dayschan, doitH, dong-li001, fary86, fuzhiye, Gaoxiong, GAO_HYP_XYJ, gengdongjie, Gogery, gongdaguo, gray0v0, gukecai, guoqi, gzhcv, hangq, hanhuifeng2020, Harshvardhan, He, heleiwang, hesham, hexia, Hoai, HuangBingjian, huangdongrun, huanghui, huangxinjing, huqi, huzhifeng, hwjiaorui, Jiabin Liu, jianghui58, Jiaqi, jin-xiulang, jinyaohui, jjfeing, John, jonyguo, JulyAi, jzg, kai00, kingfo, kingxian, kpy, kswang, liuyongqi, laiyongqiang, leonwanghui, liangchenghui, liangzelang, lichen_101010, lichenever, lihongkang, lilei, limingqi107, ling, linqingke, Lin Xh, liubuyu, liuwenhao4, liuxiao78, liuxiao93, liuyang_655, liuzhongkai, Lixia, lixian, liyanliu, liyong, lizhenyu, luopengting, lvchangquan, lvliang, lz, maning202007, Margaret_wangrui, mengyuanli, Ming_blue, ms_yan, ougongchang, panfengfeng, panyifeng, Payne, Peilin, peixu_ren, Pengyongrong, qianlong, qianjiahong, r1chardf1d0, riemann_penn, rmdyh, Sheng, shenwei41, simson, Simson, Su, sunsuodong, tao_yunhao, tinazhang, VectorSL, , Wan, wandongdong, wangdongxu, wangmin, wangyue01, wangzhe, wanyiming, Wei, wenchunjiang, wilfChen, WilliamLian, wsc, wudenggang, wukesong, wuweikang, wuxuejian, Xiao Tianci, Xiaoda, xiefangqi, xinyunfan, xuanyue, xuyongfei, yanghaitao, yanghaitao1, yanghaoran, YangLuo, yangruoqi713, yankai, yanzhenxiang2020, yao_yf, yepei6, yeyunpeng, Yi, yoni, yoonlee666, yuchaojie, yujianfeng, yuximiao, zengzitao, Zhang, zhanghuiyao, zhanghui_china, zhangxinfeng3, zhangyihui, zhangz0911gm, zhanke, zhanyuan, zhaodezan, zhaojichen, zhaoting, zhaozhenlong, zhengjun10, zhiqwang, zhoufeng, zhousiyi, zhouyaqiang, zhouyifengCode, Zichun, Ziyan, zjun, ZPaC, wangfengwfwf, zymaa, gerayking.
|
||||
|
||||
欢迎以任何形式对项目提供贡献!
|
||||
|
|
2
akg
2
akg
|
@ -1 +1 @@
|
|||
Subproject commit b591f4756eb9f04cf2bcf5bfe524a33ad92dc08d
|
||||
Subproject commit c9da0658b938c56bdf34617673774f4ebb81bcf9
|
|
@ -9,14 +9,14 @@ set(ASCEND_DRIVER_HAL_PATH ${ASCEND_PATH}/driver/lib64/driver)
|
|||
|
||||
# CANN packages
|
||||
set(ASCEND_CANN_RUNTIME_PATH ${ASCEND_PATH}/latest/lib64)
|
||||
set(ASCEND_CANN_OPP_PATH ${ASCEND_PATH}/latest/opp/op_impl/built-in/ai_core/tbe/op_tiling)
|
||||
set(ASCEND_CANN_OPP_PATH ${ASCEND_PATH}/latest/opp/built-in/op_impl/ai_core/tbe/op_tiling)
|
||||
set(ASCEND_CANN_PLUGIN_PATH ${ASCEND_CANN_RUNTIME_PATH}/plugin/opskernel)
|
||||
|
||||
# Ascend-toolkit packages
|
||||
set(ASCEND_TOOLKIT_RUNTIME_PATH ${ASCEND_PATH}/ascend-toolkit/latest/lib64)
|
||||
set(ASCEND_TOOLKIT_OPP_PATH ${ASCEND_PATH}/ascend-toolkit/latest/opp/op_impl/built-in/ai_core/tbe/op_tiling)
|
||||
set(ASCEND_TOOLKIT_OPP_PATH ${ASCEND_PATH}/ascend-toolkit/latest/opp/built-in/op_impl/ai_core/tbe/op_tiling)
|
||||
set(ASCEND_TOOLKIT_PLUGIN_PATH ${ASCEND_TOOLKIT_RUNTIME_PATH}/plugin/opskernel)
|
||||
|
||||
# nnae packages (for rpath only)
|
||||
set(ASCEND_NNAE_RUNTIME_PATH ${ASCEND_PATH}/nnae/latest/lib64)
|
||||
set(ASCEND_NNAE_OPP_PATH ${ASCEND_PATH}/nnae/latest/opp/op_impl/built-in/ai_core/tbe/op_tiling)
|
||||
set(ASCEND_NNAE_OPP_PATH ${ASCEND_PATH}/nnae/latest/opp/built-in/op_impl/ai_core/tbe/op_tiling)
|
||||
|
|
|
@ -8,6 +8,9 @@ mindspore_add_pkg(fast_transformers
|
|||
URL ${REQ_URL}
|
||||
MD5 ${MD5}
|
||||
LIBS ${ft_libs}
|
||||
LIB_PATH output/lib
|
||||
LIB_PATH lib
|
||||
PATCHES ${MINDSPORE_PROJECT_DIR}/third_party/patch/fast_transformer/001-fast_transformer.patch
|
||||
CMAKE_OPTION -DCMAKE_BUILD_TYPE=Release -DEXAMPLES=off)
|
||||
CMAKE_OPTION -DCMAKE_BUILD_TYPE=Release -DEXAMPLES=off)
|
||||
include_directories(${fast_transformers_INC})
|
||||
|
||||
add_library(mindspore::fast_transformers ALIAS fast_transformers::transformer-shared)
|
||||
|
|
|
@ -25,9 +25,13 @@ set(jpeg_turbo_LDFLAGS "-Wl,-z,relro,-z,now,-z,noexecstack,-s")
|
|||
set(jpeg_turbo_USE_STATIC_LIBS ON)
|
||||
set(JPEG_TURBO_PATCHE ${CMAKE_SOURCE_DIR}/third_party/patch/jpeg_turbo/jpeg_turbo.patch001)
|
||||
set(CMAKE_OPTION -DCMAKE_BUILD_TYPE=Release -DCMAKE_SKIP_RPATH=TRUE -DWITH_SIMD=ON)
|
||||
set(CVE_2020_35538 ${CMAKE_SOURCE_DIR}/third_party/patch/jpeg_turbo/CVE-2020-35538.patch)
|
||||
set(CVE_2021_46822 ${CMAKE_SOURCE_DIR}/third_party/patch/jpeg_turbo/CVE-2021-46822.patch)
|
||||
if(BUILD_LITE)
|
||||
set(jpeg_turbo_USE_STATIC_LIBS OFF)
|
||||
set(JPEG_TURBO_PATCHE ${TOP_DIR}/third_party/patch/jpeg_turbo/jpeg_turbo.patch001)
|
||||
set(CVE_2020_35538 ${TOP_DIR}/third_party/patch/jpeg_turbo/CVE-2020-35538.patch)
|
||||
set(CVE_2021_46822 ${TOP_DIR}/third_party/patch/jpeg_turbo/CVE-2021-46822.patch)
|
||||
if(ANDROID_NDK) # compile android on x86_64 env
|
||||
if(PLATFORM_ARM64)
|
||||
set(CMAKE_OPTION -DCMAKE_TOOLCHAIN_FILE=$ENV{ANDROID_NDK}/build/cmake/android.toolchain.cmake
|
||||
|
@ -55,6 +59,8 @@ mindspore_add_pkg(jpeg_turbo
|
|||
MD5 ${MD5}
|
||||
CMAKE_OPTION ${CMAKE_OPTION}
|
||||
PATCHES ${JPEG_TURBO_PATCHE}
|
||||
PATCHES ${CVE_2020_35538}
|
||||
PATCHES ${CVE_2021_46822}
|
||||
)
|
||||
include_directories(${jpeg_turbo_INC})
|
||||
add_library(mindspore::jpeg_turbo ALIAS jpeg_turbo::jpeg)
|
||||
|
|
|
@ -33,6 +33,10 @@ if(BUILD_LITE)
|
|||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-1292.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-2068.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-2097.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-4304.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-4450.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2023-0215.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2023-0286.patch
|
||||
)
|
||||
elseif(PLATFORM_ARM32 AND ANDROID_NDK_TOOLCHAIN_INCLUDED)
|
||||
set(openssl_USE_STATIC_LIBS OFF)
|
||||
|
@ -54,6 +58,10 @@ if(BUILD_LITE)
|
|||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-1292.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-2068.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-2097.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-4304.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-4450.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2023-0215.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2023-0286.patch
|
||||
)
|
||||
elseif(${CMAKE_SYSTEM_NAME} MATCHES "Linux" OR APPLE)
|
||||
set(openssl_CFLAGS -fvisibility=hidden)
|
||||
|
@ -70,6 +78,10 @@ if(BUILD_LITE)
|
|||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-1292.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-2068.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-2097.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-4304.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-4450.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2023-0215.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2023-0286.patch
|
||||
)
|
||||
else()
|
||||
MESSAGE(FATAL_ERROR "openssl does not support compilation for the current environment.")
|
||||
|
@ -93,6 +105,10 @@ else()
|
|||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-1292.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-2068.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-2097.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-4304.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2022-4450.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2023-0215.patch
|
||||
PATCHES ${OPENSSL_PATCH_ROOT}/CVE-2023-0286.patch
|
||||
)
|
||||
include_directories(${openssl_INC})
|
||||
add_library(mindspore::ssl ALIAS openssl::ssl)
|
||||
|
|
|
@ -1,5 +1,10 @@
|
|||
set(REQ_URL "https://github.com/martinus/robin-hood-hashing/archive/3.11.5.zip")
|
||||
set(MD5 "35154dc71e47762d9b56b2114bc906ca")
|
||||
if(ENABLE_GITEE)
|
||||
set(REQ_URL "https://gitee.com/mirrors/robin-hood-hashing/repository/archive/3.11.5.zip")
|
||||
set(MD5 "b1f36d958f0bd75671b43ccf4685a5be")
|
||||
else()
|
||||
set(REQ_URL "https://github.com/martinus/robin-hood-hashing/archive/3.11.5.zip")
|
||||
set(MD5 "35154dc71e47762d9b56b2114bc906ca")
|
||||
endif()
|
||||
set(INCLUDE "./src")
|
||||
|
||||
mindspore_add_pkg(robin_hood_hashing
|
||||
|
|
|
@ -43,6 +43,8 @@ else()
|
|||
LIBS sqlite3
|
||||
URL ${REQ_URL}
|
||||
MD5 ${MD5}
|
||||
PATCHES ${CMAKE_SOURCE_DIR}/third_party/patch/sqlite/CVE-2022-35737.patch
|
||||
PATCHES ${CMAKE_SOURCE_DIR}/third_party/patch/sqlite/CVE-2021-36690.patch
|
||||
CONFIGURE_COMMAND ./configure --enable-shared=no --disable-tcl --disable-editline --enable-json1)
|
||||
endif()
|
||||
|
||||
|
|
|
@ -11,7 +11,9 @@ mindspore_add_pkg(zlib
|
|||
LIBS z
|
||||
URL ${REQ_URL}
|
||||
MD5 ${MD5}
|
||||
CMAKE_OPTION -DCMAKE_BUILD_TYPE:STRING=Release)
|
||||
CMAKE_OPTION -DCMAKE_BUILD_TYPE:STRING=Release
|
||||
PATCHES ${CMAKE_SOURCE_DIR}/third_party/patch/zlib/CVE-2018-25032.patch
|
||||
PATCHES ${CMAKE_SOURCE_DIR}/third_party/patch/zlib/CVE-2022-37434.patch)
|
||||
|
||||
include_directories(${zlib_INC})
|
||||
add_library(mindspore::z ALIAS zlib::z)
|
||||
|
|
|
@ -58,9 +58,6 @@ endif()
|
|||
|
||||
if(ENABLE_GPU)
|
||||
include(${CMAKE_SOURCE_DIR}/cmake/external_libs/cub.cmake)
|
||||
if(NOT MSVC)
|
||||
include(${CMAKE_SOURCE_DIR}/cmake/external_libs/fast_transformers.cmake)
|
||||
endif()
|
||||
if(ENABLE_MPI)
|
||||
include(${CMAKE_SOURCE_DIR}/cmake/external_libs/nccl.cmake)
|
||||
endif()
|
||||
|
|
|
@ -852,6 +852,8 @@ else()
|
|||
if(MSLITE_GPU_BACKEND STREQUAL tensorrt)
|
||||
install(FILES ${TOP_DIR}/mindspore/lite/build/src/extendrt/delegate/tensorrt/libtensorrt_plugin.so
|
||||
DESTINATION ${RUNTIME_LIB_DIR} COMPONENT ${RUNTIME_COMPONENT_NAME})
|
||||
install(FILES ${fast_transformers_LIBPATH}/libtransformer-shared.so DESTINATION ${RUNTIME_LIB_DIR}
|
||||
COMPONENT ${RUNTIME_COMPONENT_NAME})
|
||||
endif()
|
||||
else()
|
||||
install(FILES ${TOP_DIR}/mindspore/lite/build/src/${MINDSPORE_LITE_LIB_NAME}.so DESTINATION ${RUNTIME_LIB_DIR}
|
||||
|
|
|
@ -992,7 +992,7 @@
|
|||
{"op_name": "LambApplyOptimizerAssign", "inputs": [{"index": 0, "name": "grad", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 1, "name": "inputv", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 2, "name": "inputm", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 3, "name": "input3", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 4, "name": "mul0_x", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 5, "name": "mul1_x", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 6, "name": "mul2_x", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 7, "name": "mul3_x", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 8, "name": "add2_y", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 9, "name": "steps", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 10, "name": "do_use_weight", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 11, "name": "weight_decay_rate", "need_compile": false, "param_type": "required", "shape": "all"}], "outputs": [{"index": 0, "name": "output0", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 0, "name": "inputv", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 0, "name": "inputm", "need_compile": false, "param_type": "required", "shape": "all"}], "attr": [], "fusion_type": "ELEMWISE", "dtype_format": [[["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"]], [["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"]]], "imply_type": "TBE", "async_flag": false, "binfile_name": "lamb_apply_optimizer_assign.so", "compute_cost": 10, "kernel_name": "lamb_apply_optimizer_assign", "partial_flag": true, "reshape_type": "", "dynamic_rank_support": false, "dynamic_shape": false, "dynamic_compile_static": false, "need_check_supported": false, "is_dynamic_format": false, "op_pattern": "", "real_input_index": [], "input_to_attr_index": [], "unknown_shape_formats": []}
|
||||
{"op_name": "LambApplyWeightAssign", "inputs": [{"index": 0, "name": "input0", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 1, "name": "input1", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 2, "name": "input2", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 3, "name": "input3", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 4, "name": "input_param", "need_compile": false, "param_type": "required", "shape": "all"}], "outputs": [{"index": 0, "name": "input_param", "need_compile": false, "param_type": "required", "shape": "all"}], "attr": [], "fusion_type": "ELEMWISE", "dtype_format": [[["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"]], [["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"]]], "imply_type": "TBE", "async_flag": false, "binfile_name": "lamb_apply_weight_assign.so", "compute_cost": 10, "kernel_name": "lamb_apply_weight_assign", "partial_flag": true, "reshape_type": "", "dynamic_rank_support": false, "dynamic_shape": false, "dynamic_compile_static": false, "need_check_supported": false, "is_dynamic_format": false, "op_pattern": "", "real_input_index": [], "input_to_attr_index": [], "unknown_shape_formats": []}
|
||||
{"op_name": "NLLLoss", "inputs": [{"index": 0, "name": "x", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 1, "name": "target", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 2, "name": "weight", "need_compile": false, "param_type": "required", "shape": "all"}], "outputs": [{"index": 0, "name": "y", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 1, "name": "total_weight", "need_compile": false, "param_type": "optional", "shape": "all"}], "attr": [{"name": "reduction", "param_type": "optional", "type": "str", "value": "all", "default_value": "mean"}, {"name": "ignore_index", "param_type": "optional", "type": "int", "value": "all", "default_value": "-100"}], "fusion_type": "OPAQUE", "dtype_format": [[["float32", "DefaultFormat"], ["int32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"]]], "imply_type": "TBE", "async_flag": false, "binfile_name": "nll_loss.so", "compute_cost": 10, "kernel_name": "nll_loss", "partial_flag": true, "reshape_type": "", "dynamic_rank_support": false, "dynamic_shape": false, "dynamic_compile_static": false, "need_check_supported": false, "is_dynamic_format": false, "op_pattern": "", "real_input_index": [], "input_to_attr_index": [], "unknown_shape_formats": []}
|
||||
{"op_name": "NLLLossGrad", "inputs": [{"index": 0, "name": "x", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 1, "name": "y_grad", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 2, "name": "target", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 3, "name": "weight", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 4, "name": "total_weight", "need_compile": false, "param_type": "required", "shape": "all"}], "outputs": [{"index": 0, "name": "x_grad", "need_compile": false, "param_type": "required", "shape": "all"}], "attr": [{"name": "reduction", "param_type": "optional", "type": "str", "value": "all", "default_value": "mean"}, {"name": "ignore_index", "param_type": "optional", "type": "int", "value": "all", "default_value": "-100"}], "fusion_type": "OPAQUE", "dtype_format": [[["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["int32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"]]], "imply_type": "TBE", "async_flag": false, "binfile_name": "nll_loss_grad.so", "compute_cost": 10, "kernel_name": "nll_loss_grad", "partial_flag": true, "reshape_type": "", "dynamic_rank_support": false, "dynamic_shape": false, "dynamic_compile_static": true, "need_check_supported": false, "is_dynamic_format": false, "op_pattern": "", "real_input_index": [], "input_to_attr_index": [], "unknown_shape_formats": []}
|
||||
{"op_name": "NLLLossGrad", "inputs": [{"index": 0, "name": "x", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 1, "name": "y_grad", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 2, "name": "target", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 3, "name": "weight", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 4, "name": "total_weight", "need_compile": false, "param_type": "required", "shape": "all"}], "outputs": [{"index": 0, "name": "x_grad", "need_compile": false, "param_type": "required", "shape": "all"}], "attr": [{"name": "reduction", "param_type": "optional", "type": "str", "value": "all", "default_value": "mean"}, {"name": "ignore_index", "param_type": "optional", "type": "int", "value": "all", "default_value": "-100"}], "fusion_type": "OPAQUE", "dtype_format": [[["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["int32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"]]], "imply_type": "TBE", "async_flag": false, "binfile_name": "nll_loss_grad.so", "compute_cost": 10, "kernel_name": "nll_loss_grad", "partial_flag": true, "reshape_type": "", "dynamic_rank_support": false, "dynamic_shape": true, "dynamic_compile_static": true, "need_check_supported": false, "is_dynamic_format": false, "op_pattern": "", "real_input_index": [], "input_to_attr_index": [], "unknown_shape_formats": []}
|
||||
{"op_name": "MaskedFill", "inputs": [{"index": 0, "name": "input", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 1, "name": "mask", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 2, "name": "value", "need_compile": false, "param_type": "required", "shape": "all"}], "outputs": [{"index": 0, "name": "output", "need_compile": false, "param_type": "required", "shape": "all"}], "attr": [], "fusion_type": "OPAQUE", "dtype_format": [[["float16", "DefaultFormat"], ["bool", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"]], [["float32", "DefaultFormat"], ["bool", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"]], [["int8", "DefaultFormat"], ["bool", "DefaultFormat"], ["int8", "DefaultFormat"], ["int8", "DefaultFormat"]], [["int32", "DefaultFormat"], ["bool", "DefaultFormat"], ["int32", "DefaultFormat"], ["int32", "DefaultFormat"]]], "imply_type": "TBE", "async_flag": false, "binfile_name": "masked_fill.so", "compute_cost": 10, "kernel_name": "masked_fill", "partial_flag": true, "reshape_type": "", "dynamic_rank_support": false, "dynamic_shape": false, "dynamic_compile_static": false, "need_check_supported": false, "is_dynamic_format": false, "op_pattern": "", "real_input_index": [], "input_to_attr_index": [], "unknown_shape_formats": []}
|
||||
{"op_name": "MaskedFill", "inputs": [{"index": 0, "name": "input", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 1, "name": "mask", "need_compile": false, "param_type": "required", "shape": "all"}, {"index": 2, "name": "value", "need_compile": false, "param_type": "required", "shape": "all"}], "outputs": [{"index": 0, "name": "output", "need_compile": false, "param_type": "required", "shape": "all"}], "attr": [], "fusion_type": "OPAQUE", "dtype_format": [[["float16", "DefaultFormat"], ["bool", "DefaultFormat"], ["float16", "DefaultFormat"], ["float16", "DefaultFormat"]], [["float32", "DefaultFormat"], ["bool", "DefaultFormat"], ["float32", "DefaultFormat"], ["float32", "DefaultFormat"]], [["int8", "DefaultFormat"], ["bool", "DefaultFormat"], ["int8", "DefaultFormat"], ["int8", "DefaultFormat"]], [["int32", "DefaultFormat"], ["bool", "DefaultFormat"], ["int32", "DefaultFormat"], ["int32", "DefaultFormat"]]], "imply_type": "TBE", "async_flag": false, "binfile_name": "masked_fill.so", "compute_cost": 10, "kernel_name": "masked_fill", "partial_flag": true, "reshape_type": "", "dynamic_rank_support": false, "dynamic_shape": true, "dynamic_compile_static": false, "need_check_supported": false, "is_dynamic_format": false, "op_pattern": "", "real_input_index": [], "input_to_attr_index": [], "unknown_shape_formats": []}
|
||||
{"op_name": "Mish", "inputs": [{"index": 0, "name": "x", "need_compile": false, "param_type": "required", "shape": "all"}], "outputs": [{"index": 0, "name": "y", "need_compile": false, "param_type": "required", "shape": "all"}], "attr": [], "fusion_type": "ELEMWISE", "dtype_format": [[["float16", ""], ["float16", ""]], [["float32", ""], ["float32", ""]]], "imply_type": "TBE", "async_flag": false, "binfile_name": "mish.so", "compute_cost": 10, "kernel_name": "mish", "partial_flag": true, "reshape_type": "", "dynamic_rank_support": false, "dynamic_shape": false, "dynamic_compile_static": false, "need_check_supported": false, "is_dynamic_format": false, "op_pattern": "formatAgnostic", "real_input_index": [], "input_to_attr_index": [], "unknown_shape_formats": []}
|
||||
|
|
Binary file not shown.
Before ![]() (image error) Size: 36 KiB After ![]() (image error) Size: 199 KiB ![]() ![]() |
Binary file not shown.
Before ![]() (image error) Size: 44 KiB After ![]() (image error) Size: 230 KiB ![]() ![]() |
|
@ -29,9 +29,15 @@ mindspore.amp.DynamicLossScaler
|
|||
参数:
|
||||
- **inputs** (Union(Tensor, tuple(Tensor))) - 损失值或梯度。
|
||||
|
||||
返回:
|
||||
Union(Tensor, tuple(Tensor)),scale后的值。
|
||||
|
||||
.. py:method:: unscale(inputs)
|
||||
|
||||
对inputs进行unscale,`inputs /= scale_value`。
|
||||
|
||||
参数:
|
||||
- **inputs** (Union(Tensor, tuple(Tensor))) - 损失值或梯度。
|
||||
|
||||
返回:
|
||||
Union(Tensor, tuple(Tensor)),unscale后的值。
|
||||
|
|
|
@ -5,7 +5,7 @@ mindspore.amp.LossScaleManager
|
|||
|
||||
使用混合精度时,用于管理损失缩放系数(loss scale)的抽象类。
|
||||
|
||||
派生类需要实现该类的所有方法。 `get_loss_scale` 用于获取当前的梯度放大系数。 `update_loss_scale` 用于更新梯度放大系数,该方法将在训练过程中被调用。 `get_update_cell` 用于获取更新梯度放大系数的 `Cell` 实例,该实例将在训练过程中被调用。当前多使用 `get_update_cell` 方式。
|
||||
派生类需要实现该类的所有方法。 `get_loss_scale` 用于获取当前的梯度放大系数。 `update_loss_scale` 用于更新梯度放大系数,该方法将在训练过程中被调用。 `get_update_cell` 用于获取更新梯度放大系数的 :class:`mindspore.nn.Cell` 实例,该实例将在训练过程中被调用。当前多使用 `get_update_cell` 方式。
|
||||
|
||||
例如::class:`mindspore.amp.FixedLossScaleManager` 和 :class:`mindspore.amp.DynamicLossScaleManager` 。
|
||||
|
||||
|
|
|
@ -25,9 +25,15 @@ mindspore.amp.StaticLossScaler
|
|||
参数:
|
||||
- **inputs** (Union(Tensor, tuple(Tensor))) - 损失值或梯度。
|
||||
|
||||
返回:
|
||||
Union(Tensor, tuple(Tensor)),scale后的值。
|
||||
|
||||
.. py:method:: unscale(inputs)
|
||||
|
||||
对inputs进行unscale,`inputs /= scale_value`。
|
||||
|
||||
参数:
|
||||
- **inputs** (Union(Tensor, tuple(Tensor))) - 损失值或梯度。
|
||||
|
||||
返回:
|
||||
Union(Tensor, tuple(Tensor)),unscale后的值。
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
mindspore.amp.all_finite
|
||||
========================
|
||||
|
||||
.. py:function:: mindspore.amp.all_finite(inputs)
|
||||
.. py:function:: mindspore.amp.all_finite(inputs, status=None)
|
||||
|
||||
检查inputs是否是有效值(无溢出)。
|
||||
|
||||
|
@ -12,6 +12,7 @@ mindspore.amp.all_finite
|
|||
|
||||
参数:
|
||||
- **inputs** (Union(tuple(Tensor), list(Tensor))) - 可迭代的Tensor。
|
||||
- **status** (Tensor) - 溢出检测时所需要的初始状态,仅在Ascend需要。默认值:None。
|
||||
|
||||
返回:
|
||||
Tensor, 布尔类型的标量Tensor。
|
||||
Tensor,布尔类型的标量Tensor。
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
mindspore.amp.init_status
|
||||
===========================
|
||||
|
||||
.. py:function:: mindspore.amp.init_status()
|
||||
|
||||
初始化溢出状态检测变量。
|
||||
|
||||
.. note::
|
||||
该接口仅在Ascend后端有效,在GPU、CPU上调用的返回值没有作用。
|
||||
|
||||
返回:
|
||||
Tensor,shape为 (8,) 。
|
|
@ -1,72 +0,0 @@
|
|||
mindspore.dataset.AGNewsDataset
|
||||
===============================
|
||||
|
||||
.. py:class:: mindspore.dataset.AGNewsDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析AG News数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有三列 `[index, title, description]` ,三列的数据类型均为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test'或'all'。默认值:None,读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取所有样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
**关于AGNews数据集:**
|
||||
|
||||
AG是一个大型合集,具有超过100万篇新闻文章。这些新闻文章是由ComeToMyHead在持续1年多的活动中,从2000多个新闻来源收集的。ComeToMyHead是一个学术新闻搜索引擎,自2004年7月以来一直在运营。
|
||||
数据集由学者提供,用于研究目的,如数据挖掘(聚类、分类等)、信息检索(排名、搜索等)、xml、数据压缩、数据流和任何其他非商业活动。
|
||||
AG的新闻主题类别来自于原始语料库中四个最大的类别。每个分类包含30000个训练样本和1900个测试样本。train.csv中的训练样本总数为12万,test.csv中的测试样本总数为7600。
|
||||
|
||||
可以将数据集文件解压缩到以下结构中,并通过MindSpore的API读取:
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── ag_news_dataset_dir
|
||||
├── classes.txt
|
||||
├── train.csv
|
||||
├── test.csv
|
||||
└── readme.txt
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@misc{zhang2015characterlevel,
|
||||
title={Character-level Convolutional Networks for Text Classification},
|
||||
author={Xiang Zhang and Junbo Zhao and Yann LeCun},
|
||||
year={2015},
|
||||
eprint={1509.01626},
|
||||
archivePrefix={arXiv},
|
||||
primaryClass={cs.LG}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,82 +0,0 @@
|
|||
mindspore.dataset.AmazonReviewDataset
|
||||
=====================================
|
||||
|
||||
.. py:class:: mindspore.dataset.AmazonReviewDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析Amazon Review Full和Amazon Review Polarity数据集的源数据集。
|
||||
|
||||
生成的数据集有三列 `[label, title, content]` ,三列的数据类型均为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test'或'all'。
|
||||
对于Polarity数据集,'train'将读取360万个训练样本,'test'将读取40万个测试样本,'all'将读取所有400万个样本。
|
||||
对于Full数据集,'train'将读取300万个训练样本,'test'将读取65万个测试样本,'all'将读取所有365万个样本。默认值:None,读取所有样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 参数所指向的文件目录不存在或缺少数据集文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
|
||||
**关于AGNews数据集:**
|
||||
|
||||
Amazon Review Full数据集包括来自亚马逊的评论数据,这些数据跨越18年,包括截止至2013年3月的约3500万条评论。评论数据包括产品和用户信息、产品评级和产品评论。
|
||||
数据集主要用于文本分类,给定内容和标题,预测正确的星级评定。
|
||||
|
||||
Amazon Review Polarity数据集对产品评分进行了分级,评论分数1和2视为负面评论,4和5视为正面评论。
|
||||
评分3的样本则被忽略。
|
||||
|
||||
Amazon Reviews Polarity和Amazon Reviews Full datasets具有相同的目录结构。
|
||||
可以将数据集文件解压缩到以下结构,并通过MindSpore的API读取:
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── amazon_review_dir
|
||||
├── train.csv
|
||||
├── test.csv
|
||||
└── readme.txt
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{zhang2015character,
|
||||
title={Character-level convolutional networks for text classification},
|
||||
author={Zhang, Xiang and Zhao, Junbo and LeCun, Yann},
|
||||
journal={Advances in neural information processing systems},
|
||||
volume={28},
|
||||
pages={649--657},
|
||||
year={2015}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,50 +1,50 @@
|
|||
mindspore.dataset.ArgoverseDataset
|
||||
====================================
|
||||
|
||||
.. py:class:: mindspore.dataset.ArgoverseDataset(data_dir, column_names="graph", shuffle=None, num_parallel_workers=1, python_multiprocessing=True, perf_mode=True)
|
||||
|
||||
加载argoverse数据集并进行图(Graph)初始化。
|
||||
|
||||
Argoverse数据集是自动驾驶领域的公共数据集,当前实现的 `ArgoverseDataset` 主要用于加载argoverse数据集中运动预测(Motion Forecasting)场景的数据集,具体信息可访问官网了解:
|
||||
https://www.argoverse.org/av1.html#download-link
|
||||
|
||||
参数:
|
||||
- **data_dir** (str) - 加载数据集的目录,这里包含原始格式的数据,并将在 `process` 方法中被加载。
|
||||
- **column_names** (Union[str, list[str]],可选) - dataset包含的单个列名或多个列名组成的列表,默认值:'Graph'。当实现类似 `__getitem__` 等方法时,列名的数量应该等于该方法中返回数据的条数,如下述示例,建议初始化时明确它的取值如:`column_names=["edge_index", "x", "y", "cluster", "valid_len", "time_step_len"]`。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作进程数/线程数(由参数 `python_multiprocessing` 决定当前为多进程模式或多线程模式),默认值:1。
|
||||
- **shuffle** (bool,可选) - 是否混洗数据集。当实现的Dataset带有可随机访问属性( `__getitem__` )时,才可以指定该参数。默认值:None。
|
||||
- **python_multiprocessing** (bool,可选) - 启用Python多进程模式加速运算,默认值:True。当传入 `source` 的Python对象的计算量很大时,开启此选项可能会有较好效果。
|
||||
- **perf_mode** (bool,可选) - 遍历创建的dataset对象时获得更高性能的模式(在此过程中将调用 `__getitem__` 方法)。默认值:True,将Graph的所有数据(如边的索引、节点特征和图的特征)都作为图特征进行存储。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. py:method:: load()
|
||||
|
||||
从给定(处理好的)路径加载数据,也可以在自己实现的Dataset类中实现这个方法。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. py:method:: process()
|
||||
|
||||
针对argoverse数据集的处理方法,基于加载上来的原始数据集创建很多子图。
|
||||
数据预处理方法主要参考:https://github.com/xk-huang/yet-another-vectornet/blob/master/dataset.py。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. py:method:: save()
|
||||
|
||||
将经过 `process` 函数处理后的数据以 numpy.npz 格式保存到磁盘中,也可以在自己实现的Dataset类中自己实现这个方法。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
||||
mindspore.dataset.ArgoverseDataset
|
||||
====================================
|
||||
|
||||
.. py:class:: mindspore.dataset.ArgoverseDataset(data_dir, column_names="graph", shuffle=None, num_parallel_workers=1, python_multiprocessing=True, perf_mode=True)
|
||||
|
||||
加载argoverse数据集并进行图(Graph)初始化。
|
||||
|
||||
Argoverse数据集是自动驾驶领域的公共数据集,当前实现的 `ArgoverseDataset` 主要用于加载argoverse数据集中运动预测(Motion Forecasting)场景的数据集,具体信息可访问官网了解:
|
||||
https://www.argoverse.org/av1.html#download-link。
|
||||
|
||||
参数:
|
||||
- **data_dir** (str) - 加载数据集的目录,这里包含原始格式的数据,并将在 `process` 方法中被加载。
|
||||
- **column_names** (Union[str, list[str]],可选) - dataset包含的单个列名或多个列名组成的列表,默认值:'Graph'。当实现类似 `__getitem__` 等方法时,列名的数量应该等于该方法中返回数据的条数,如下述示例,建议初始化时明确它的取值如:`column_names=["edge_index", "x", "y", "cluster", "valid_len", "time_step_len"]`。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作进程数/线程数(由参数 `python_multiprocessing` 决定当前为多进程模式或多线程模式),默认值:1。
|
||||
- **shuffle** (bool,可选) - 是否混洗数据集。当实现的Dataset带有可随机访问属性( `__getitem__` )时,才可以指定该参数。默认值:None。
|
||||
- **python_multiprocessing** (bool,可选) - 启用Python多进程模式加速运算,默认值:True。当传入 `source` 的Python对象的计算量很大时,开启此选项可能会有较好效果。
|
||||
- **perf_mode** (bool,可选) - 遍历创建的dataset对象时获得更高性能的模式(在此过程中将调用 `__getitem__` 方法)。默认值:True,将Graph的所有数据(如边的索引、节点特征和图的特征)都作为图特征进行存储。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. py:method:: load()
|
||||
|
||||
从给定(处理好的)路径加载数据,也可以在自己实现的Dataset类中实现这个方法。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. py:method:: process()
|
||||
|
||||
针对argoverse数据集的处理方法,基于加载上来的原始数据集创建很多子图。
|
||||
数据预处理方法主要参考:https://github.com/xk-huang/yet-another-vectornet/blob/master/dataset.py。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. py:method:: save()
|
||||
|
||||
将经过 `process` 函数处理后的数据以 numpy.npz 格式保存到磁盘中,也可以在自己实现的Dataset类中自己实现这个方法。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
|
||||
.. py:method:: get_num_samples()
|
||||
|
||||
返回采样器采集样本数量,如果存在子采样器,则子采样器计数可以是数值或None。这些条件会影响最终的采样结果。
|
||||
获取当前采样器实例的num_samples参数值。此参数在定义Sampler时,可以选择性传入(默认为None)。此方法将返回num_samples的值,如果当前采样器有子采样器,会继续访问子采样器,并根据一定的规则处理获取值。
|
||||
|
||||
下表显示了调用此函数的可能结果。
|
||||
下表显示了各种可能的组合,以及最终返回的结果。
|
||||
|
||||
.. list-table::
|
||||
:widths: 25 25 25 25
|
||||
|
|
|
@ -22,7 +22,7 @@ mindspore.dataset.CLUEDataset
|
|||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
根据给定的 `task` 参数 和 `usage` 配置,数据集会生成不同的输出列:
|
||||
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_files` 参数所指向的文件无效或不存在。
|
||||
|
|
|
@ -16,7 +16,7 @@ mindspore.dataset.Caltech256Dataset
|
|||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
|
|
|
@ -18,7 +18,7 @@ mindspore.dataset.CelebADataset
|
|||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **decrypt** (callable, 可选) - 图像解密函数,接受加密的图片路径并返回bytes类型的解密数据。默认值:None,不进行解密。
|
||||
|
||||
异常:
|
||||
|
|
|
@ -1,103 +1,103 @@
|
|||
mindspore.dataset.Cifar100Dataset
|
||||
=================================
|
||||
|
||||
.. py:class:: mindspore.dataset.Cifar100Dataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析CIFAR-100数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有三列: `[image, coarse_label, fine_label]` 。 `image` 列的数据类型为uint8。 `coarse_label` 和 `fine_labels` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test'或'all'。
|
||||
取值为'train'时将会读取50,000个训练样本,取值为'test'时将会读取10,000个测试样本,取值为'all'时将会读取全部60,000个样本。默认值:None,读取全部样本图片。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **ValueError** - `usage` 参数取值不为'train'、'test'或'all'。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards`)。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于CIFAR-100数据集:**
|
||||
|
||||
CIFAR-100数据集和CIFAR-10数据集非常相似,CIFAR-100有100个类别,每类包含600张图片,其中500张训练图片和100张测试图片。这100个类别又被分成20个超类。每个图片都有一个"fine"标签(所属子类)和一个"coarse"标签(所属超类)。
|
||||
|
||||
以下为原始CIFAR-100数据集的结构,您可以将数据集文件解压得到如下的文件结构,并通过MindSpore的API进行读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── cifar-100-binary
|
||||
├── train.bin
|
||||
├── test.bin
|
||||
├── fine_label_names.txt
|
||||
└── coarse_label_names.txt
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@techreport{Krizhevsky09,
|
||||
author = {Alex Krizhevsky},
|
||||
title = {Learning multiple layers of features from tiny images},
|
||||
institution = {},
|
||||
year = {2009},
|
||||
howpublished = {http://www.cs.toronto.edu/~kriz/cifar.html}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
mindspore.dataset.Cifar100Dataset
|
||||
=================================
|
||||
|
||||
.. py:class:: mindspore.dataset.Cifar100Dataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析CIFAR-100数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有三列: `[image, coarse_label, fine_label]` 。 `image` 列的数据类型为uint8。 `coarse_label` 和 `fine_labels` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test'或'all'。
|
||||
取值为'train'时将会读取50,000个训练样本,取值为'test'时将会读取10,000个测试样本,取值为'all'时将会读取全部60,000个样本。默认值:None,读取全部样本图片。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **ValueError** - `usage` 参数取值不为'train'、'test'或'all'。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards`)。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于CIFAR-100数据集:**
|
||||
|
||||
CIFAR-100数据集和CIFAR-10数据集非常相似,CIFAR-100有100个类别,每类包含600张图片。其中500张训练图片和100张测试图片。这100个类别又被分成20个超类。每个图片都有一个"fine"标签(所属子类)和一个"coarse"标签(所属超类)。
|
||||
|
||||
以下为原始CIFAR-100数据集的结构。您可以将数据集文件解压得到如下的文件结构,并通过MindSpore的API进行读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── cifar-100-binary
|
||||
├── train.bin
|
||||
├── test.bin
|
||||
├── fine_label_names.txt
|
||||
└── coarse_label_names.txt
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@techreport{Krizhevsky09,
|
||||
author = {Alex Krizhevsky},
|
||||
title = {Learning multiple layers of features from tiny images},
|
||||
institution = {},
|
||||
year = {2009},
|
||||
howpublished = {http://www.cs.toronto.edu/~kriz/cifar.html}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,107 +1,107 @@
|
|||
mindspore.dataset.Cifar10Dataset
|
||||
================================
|
||||
|
||||
.. py:class:: mindspore.dataset.Cifar10Dataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析CIFAR-10数据集的源文件构建数据集。该API目前仅支持解析二进制版本的CIFAR-10文件(CIFAR-10 binary version)。
|
||||
|
||||
生成的数据集有两列: `[image, label]` 。 `image` 列的数据类型是uint8。`label` 列的数据类型是uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test'或'all'。
|
||||
取值为'train'时将会读取50,000个训练样本,取值为'test'时将会读取10,000个测试样本,取值为'all'时将会读取全部60,000个样本。默认值:None,读取全部样本图片。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **ValueError** - `usage` 参数取值不为'train'、'test'或'all'。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于CIFAR-10数据集:**
|
||||
|
||||
CIFAR-10数据集由60000张32x32彩色图片组成,总共有10个类别,每类6000张图片。有50000个训练样本和10000个测试样本。10个类别包含飞机、汽车、鸟类、猫、鹿、狗、青蛙、马、船和卡车。
|
||||
|
||||
以下为原始CIFAR-10数据集的结构,您可以将数据集文件解压得到如下的文件结构,并通过MindSpore的API进行读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── cifar-10-batches-bin
|
||||
├── data_batch_1.bin
|
||||
├── data_batch_2.bin
|
||||
├── data_batch_3.bin
|
||||
├── data_batch_4.bin
|
||||
├── data_batch_5.bin
|
||||
├── test_batch.bin
|
||||
├── readme.html
|
||||
└── batches.meta.text
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@techreport{Krizhevsky09,
|
||||
author = {Alex Krizhevsky},
|
||||
title = {Learning multiple layers of features from tiny images},
|
||||
institution = {},
|
||||
year = {2009},
|
||||
howpublished = {http://www.cs.toronto.edu/~kriz/cifar.html}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
mindspore.dataset.Cifar10Dataset
|
||||
================================
|
||||
|
||||
.. py:class:: mindspore.dataset.Cifar10Dataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析CIFAR-10数据集的源文件构建数据集。该API目前仅支持解析二进制版本的CIFAR-10文件(CIFAR-10 binary version)。
|
||||
|
||||
生成的数据集有两列: `[image, label]` 。 `image` 列的数据类型是uint8。`label` 列的数据类型是uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test'或'all'。
|
||||
取值为'train'时将会读取50,000个训练样本,取值为'test'时将会读取10,000个测试样本,取值为'all'时将会读取全部60,000个样本。默认值:None,读取全部样本图片。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **ValueError** - `usage` 参数取值不为'train'、'test'或'all'。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于CIFAR-10数据集:**
|
||||
|
||||
CIFAR-10数据集由60000张32x32彩色图片组成,总共有10个类别,每类6000张图片。有50000个训练样本和10000个测试样本。10个类别包含飞机、汽车、鸟类、猫、鹿、狗、青蛙、马、船和卡车。
|
||||
|
||||
以下为原始CIFAR-10数据集的结构,您可以将数据集文件解压得到如下的文件结构,并通过MindSpore的API进行读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── cifar-10-batches-bin
|
||||
├── data_batch_1.bin
|
||||
├── data_batch_2.bin
|
||||
├── data_batch_3.bin
|
||||
├── data_batch_4.bin
|
||||
├── data_batch_5.bin
|
||||
├── test_batch.bin
|
||||
├── readme.html
|
||||
└── batches.meta.text
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@techreport{Krizhevsky09,
|
||||
author = {Alex Krizhevsky},
|
||||
title = {Learning multiple layers of features from tiny images},
|
||||
institution = {},
|
||||
year = {2009},
|
||||
howpublished = {http://www.cs.toronto.edu/~kriz/cifar.html}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -6,7 +6,7 @@ mindspore.dataset.CityscapesDataset
|
|||
读取和解析Cityscapes数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列 `[image, task]` 。
|
||||
`image` 列的数据类型为uint8。`task` 列的数据类型根据参数 `task` 的值而定,当 参数 `task` 取值为'polygon',列的数据类型为string,其他取值下,列的数据类型为uint8。
|
||||
`image` 列的数据类型为uint8。`task` 列的数据类型根据参数 `task` 的值而定,当参数 `task` 取值为'polygon',列的数据类型为string,其他取值下,列的数据类型为uint8。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
|
@ -21,7 +21,7 @@ mindspore.dataset.CityscapesDataset
|
|||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
|
|
|
@ -1,80 +0,0 @@
|
|||
mindspore.dataset.CoNLL2000Dataset
|
||||
==================================
|
||||
|
||||
.. py:class:: mindspore.dataset.CoNLL2000Dataset(dataset_dir, usage=None, num_samples=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, num_parallel_workers=None, cache=None)
|
||||
|
||||
读取和解析CoNLL2000分块数据集的源数据集。
|
||||
|
||||
生成的数据集有三列 `[word, pos_tag, chunk_tag]` 。三列的数据类型均为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含CoNLL2000分块数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test'或'all'。
|
||||
'train'将读取8936个训练样本,'test'将读取2,012个测试样本中,'all'将读取所有1,0948个样本。默认值:None,读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取所有样本。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式。默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗。如果 `shuffle` 为True,执行全局混洗。
|
||||
总共有三种混洗模式,通过枚举变量mindspore.dataset.Shuffle指定。
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本,与设置为True效果相同。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数。指定此参数后, `num_samples` 表示每个分片的最大样本数。默认值:None。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号。只有当指定了 `num_shards` 时才能指定此参数。默认值:None。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 参数所指向的文件目录不存在或缺少数据集文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
|
||||
**关于CoNLL2000数据集:**
|
||||
|
||||
CoNLL2000分块数据集由华尔街日报语料库第15-20节的文本组成。
|
||||
文本使用IOB表示法进行分块,分块类型有NP, VP, PP, ADJP和ADVP。
|
||||
数据集由通过空格分隔的三列组成。第一列包含当前单词,第二列是由Brill标注器派生的词性标注,第三列是由华尔街语料库派生的分块标注。
|
||||
文本分块旨在将文本划分为单词的句法的相关组成部分。
|
||||
|
||||
可以将数据集文件解压缩到以下结构,并通过MindSpore的API读取:
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── conll2000_dataset_dir
|
||||
├── train.txt
|
||||
├── test.txt
|
||||
└── readme.txt
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@inproceedings{tksbuchholz2000conll,
|
||||
author = {Tjong Kim Sang, Erik F. and Sabine Buchholz},
|
||||
title = {Introduction to the CoNLL-2000 Shared Task: Chunking},
|
||||
editor = {Claire Cardie and Walter Daelemans and Claire Nedellec and Tjong Kim Sang, Erik},
|
||||
booktitle = {Proceedings of CoNLL-2000 and LLL-2000},
|
||||
publisher = {Lisbon, Portugal},
|
||||
pages = {127--132},
|
||||
year = {2000}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,170 +1,170 @@
|
|||
mindspore.dataset.CocoDataset
|
||||
==============================
|
||||
|
||||
.. py:class:: mindspore.dataset.CocoDataset(dataset_dir, annotation_file, task='Detection', num_samples=None, num_parallel_workers=None, shuffle=None, decode=False, sampler=None, num_shards=None, shard_id=None, cache=None, extra_metadata=False, decrypt=None)
|
||||
|
||||
读取和解析COCO数据集的源文件构建数据集。该API支持解析COCO2017数据集,支持四种类型的机器学习任务,分别是目标检测、关键点检测、物体分割和全景分割。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **annotation_file** (str) - 数据集标注JSON文件的路径。
|
||||
- **task** (str, 可选) - 指定COCO数据的任务类型。支持的任务类型包括:'Detection'、'Stuff' 、'Panoptic'和'Keypoint'。默认值:'Detection'。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数,默认值:使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,表2中会展示不同参数配置的预期行为。
|
||||
- **decode** (bool, 可选) - 是否对读取的图片进行解码操作,默认值:False,不解码。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,表2中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **extra_metadata** (bool, 可选) - 用于指定是否额外输出一个数据列用于表示图片元信息。如果为True,则将额外输出一个名为 `[_meta-filename, dtype=string]` 的数据列,默认值:False。
|
||||
- **decrypt** (callable, 可选) - 图像解密函数,接受加密的图片路径并返回bytes类型的解密数据。默认值:None,不进行解密。
|
||||
|
||||
[表1] 根据不同 `task` 参数设置,生成数据集具有不同的输出列:
|
||||
|
||||
+-------------------------+----------------------------------------------+
|
||||
| `task` | 输出列 |
|
||||
+=========================+==============================================+
|
||||
| Detection | [image, dtype=uint8] |
|
||||
| | |
|
||||
| | [bbox, dtype=float32] |
|
||||
| | |
|
||||
| | [category_id, dtype=uint32] |
|
||||
| | |
|
||||
| | [iscrowd, dtype=uint32] |
|
||||
+-------------------------+----------------------------------------------+
|
||||
| Stuff | [image, dtype=uint8] |
|
||||
| | |
|
||||
| | [segmentation, dtype=float32] |
|
||||
| | |
|
||||
| | [iscrowd, dtype=uint32] |
|
||||
+-------------------------+----------------------------------------------+
|
||||
| Keypoint | [image, dtype=uint8] |
|
||||
| | |
|
||||
| | [keypoints, dtype=float32] |
|
||||
| | |
|
||||
| | [num_keypoints, dtype=uint32] |
|
||||
+-------------------------+----------------------------------------------+
|
||||
| Panoptic | [image, dtype=uint8] |
|
||||
| | |
|
||||
| | [bbox, dtype=float32] |
|
||||
| | |
|
||||
| | [category_id, dtype=uint32] |
|
||||
| | |
|
||||
| | [iscrowd, dtype=uint32] |
|
||||
| | |
|
||||
| | [area, dtype=uint32] |
|
||||
+-------------------------+----------------------------------------------+
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **RuntimeError** - 解析 `annotation_file` 指定的JSON文件失败。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **ValueError** - `task` 参数取值不为 `Detection` 、 `Stuff` 、`Panoptic` 或 `Keypoint` 。
|
||||
- **ValueError** - `annotation_file` 参数对应的文件不存在。
|
||||
- **ValueError** - `dataset_dir` 参数路径不存在。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note::
|
||||
- 当参数 `extra_metadata` 为True时,还需使用 `rename` 操作删除额外数据列'_meta-filename'的前缀'_meta-',
|
||||
否则迭代得到的数据行中不会出现此额外数据列。
|
||||
- CocoDataset的 `sampler` 参数不支持指定PKSampler。
|
||||
- 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: [表2] 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于COCO数据集:**
|
||||
|
||||
Microsoft Common Objects in Context(COCO)是一个大型数据集,该数据集专门为目标检测,语义分割和字幕生成任务而设计。它拥有330K张图像(标记数量大于200K个)、1500000个目标实例、80个目标类别、91个对象类别、每张图片均有5个字幕、带关键点标注的人有250000个。与流行的ImageNet数据集相比,COCO的类别较少,但每个类别中的图片样本非常多。
|
||||
|
||||
您可以解压缩原始COCO-2017数据集文件得到如下目录结构,并通过MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── coco_dataset_directory
|
||||
├── train2017
|
||||
│ ├── 000000000009.jpg
|
||||
│ ├── 000000000025.jpg
|
||||
│ ├── ...
|
||||
├── test2017
|
||||
│ ├── 000000000001.jpg
|
||||
│ ├── 000000058136.jpg
|
||||
│ ├── ...
|
||||
├── val2017
|
||||
│ ├── 000000000139.jpg
|
||||
│ ├── 000000057027.jpg
|
||||
│ ├── ...
|
||||
└── annotation
|
||||
├── captions_train2017.json
|
||||
├── captions_val2017.json
|
||||
├── instances_train2017.json
|
||||
├── instances_val2017.json
|
||||
├── person_keypoints_train2017.json
|
||||
└── person_keypoints_val2017.json
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{DBLP:journals/corr/LinMBHPRDZ14,
|
||||
author = {Tsung{-}Yi Lin and Michael Maire and Serge J. Belongie and
|
||||
Lubomir D. Bourdev and Ross B. Girshick and James Hays and
|
||||
Pietro Perona and Deva Ramanan and Piotr Doll{\'{a}}r and C. Lawrence Zitnick},
|
||||
title = {Microsoft {COCO:} Common Objects in Context},
|
||||
journal = {CoRR},
|
||||
volume = {abs/1405.0312},
|
||||
year = {2014},
|
||||
url = {http://arxiv.org/abs/1405.0312},
|
||||
archivePrefix = {arXiv},
|
||||
eprint = {1405.0312},
|
||||
timestamp = {Mon, 13 Aug 2018 16:48:13 +0200},
|
||||
biburl = {https://dblp.org/rec/journals/corr/LinMBHPRDZ14.bib},
|
||||
bibsource = {dblp computer science bibliography, https://dblp.org}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
mindspore.dataset.CocoDataset
|
||||
==============================
|
||||
|
||||
.. py:class:: mindspore.dataset.CocoDataset(dataset_dir, annotation_file, task='Detection', num_samples=None, num_parallel_workers=None, shuffle=None, decode=False, sampler=None, num_shards=None, shard_id=None, cache=None, extra_metadata=False, decrypt=None)
|
||||
|
||||
读取和解析COCO数据集的源文件构建数据集。该API支持解析COCO2017数据集,支持四种类型的机器学习任务,分别是目标检测、关键点检测、物体分割和全景分割。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **annotation_file** (str) - 数据集标注JSON文件的路径。
|
||||
- **task** (str, 可选) - 指定COCO数据的任务类型。支持的任务类型包括:'Detection'、'Stuff' 、'Panoptic'和'Keypoint'。默认值:'Detection'。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数,默认值:使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,表2中会展示不同参数配置的预期行为。
|
||||
- **decode** (bool, 可选) - 是否对读取的图片进行解码操作,默认值:False,不解码。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,表2中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **extra_metadata** (bool, 可选) - 用于指定是否额外输出一个数据列用于表示图片元信息。如果为True,则将额外输出一个名为 `[_meta-filename, dtype=string]` 的数据列,默认值:False。
|
||||
- **decrypt** (callable, 可选) - 图像解密函数,接受加密的图片路径并返回bytes类型的解密数据。默认值:None,不进行解密。
|
||||
|
||||
[表1] 根据不同 `task` 参数设置,生成数据集具有不同的输出列:
|
||||
|
||||
+-------------------------+----------------------------------------------+
|
||||
| `task` | 输出列 |
|
||||
+=========================+==============================================+
|
||||
| Detection | [image, dtype=uint8] |
|
||||
| | |
|
||||
| | [bbox, dtype=float32] |
|
||||
| | |
|
||||
| | [category_id, dtype=uint32] |
|
||||
| | |
|
||||
| | [iscrowd, dtype=uint32] |
|
||||
+-------------------------+----------------------------------------------+
|
||||
| Stuff | [image, dtype=uint8] |
|
||||
| | |
|
||||
| | [segmentation, dtype=float32] |
|
||||
| | |
|
||||
| | [iscrowd, dtype=uint32] |
|
||||
+-------------------------+----------------------------------------------+
|
||||
| Keypoint | [image, dtype=uint8] |
|
||||
| | |
|
||||
| | [keypoints, dtype=float32] |
|
||||
| | |
|
||||
| | [num_keypoints, dtype=uint32] |
|
||||
+-------------------------+----------------------------------------------+
|
||||
| Panoptic | [image, dtype=uint8] |
|
||||
| | |
|
||||
| | [bbox, dtype=float32] |
|
||||
| | |
|
||||
| | [category_id, dtype=uint32] |
|
||||
| | |
|
||||
| | [iscrowd, dtype=uint32] |
|
||||
| | |
|
||||
| | [area, dtype=uint32] |
|
||||
+-------------------------+----------------------------------------------+
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **RuntimeError** - 解析 `annotation_file` 指定的JSON文件失败。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **ValueError** - `task` 参数取值不为 `Detection` 、 `Stuff` 、`Panoptic` 或 `Keypoint` 。
|
||||
- **ValueError** - `annotation_file` 参数对应的文件不存在。
|
||||
- **ValueError** - `dataset_dir` 参数路径不存在。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note::
|
||||
- 当参数 `extra_metadata` 为True时,还需使用 `rename` 操作删除额外数据列'_meta-filename'的前缀'_meta-',
|
||||
否则迭代得到的数据行中不会出现此额外数据列。
|
||||
- CocoDataset的 `sampler` 参数不支持指定PKSampler。
|
||||
- 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: [表2] 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于COCO数据集:**
|
||||
|
||||
Microsoft Common Objects in Context(COCO)是一个大型数据集,该数据集专门为目标检测,语义分割和字幕生成任务而设计。它拥有330K张图像(标记数量大于200K个)、1500000个目标实例、80个目标类别、91个对象类别、每张图片均有5个字幕、带关键点标注的人有250000个。与流行的ImageNet数据集相比,COCO的类别较少,但每个类别中的图片样本非常多。
|
||||
|
||||
您可以解压缩原始COCO-2017数据集文件得到如下目录结构,并通过MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── coco_dataset_directory
|
||||
├── train2017
|
||||
│ ├── 000000000009.jpg
|
||||
│ ├── 000000000025.jpg
|
||||
│ ├── ...
|
||||
├── test2017
|
||||
│ ├── 000000000001.jpg
|
||||
│ ├── 000000058136.jpg
|
||||
│ ├── ...
|
||||
├── val2017
|
||||
│ ├── 000000000139.jpg
|
||||
│ ├── 000000057027.jpg
|
||||
│ ├── ...
|
||||
└── annotation
|
||||
├── captions_train2017.json
|
||||
├── captions_val2017.json
|
||||
├── instances_train2017.json
|
||||
├── instances_val2017.json
|
||||
├── person_keypoints_train2017.json
|
||||
└── person_keypoints_val2017.json
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{DBLP:journals/corr/LinMBHPRDZ14,
|
||||
author = {Tsung{-}Yi Lin and Michael Maire and Serge J. Belongie and
|
||||
Lubomir D. Bourdev and Ross B. Girshick and James Hays and
|
||||
Pietro Perona and Deva Ramanan and Piotr Doll{\'{a}}r and C. Lawrence Zitnick},
|
||||
title = {Microsoft {COCO:} Common Objects in Context},
|
||||
journal = {CoRR},
|
||||
volume = {abs/1405.0312},
|
||||
year = {2014},
|
||||
url = {http://arxiv.org/abs/1405.0312},
|
||||
archivePrefix = {arXiv},
|
||||
eprint = {1405.0312},
|
||||
timestamp = {Mon, 13 Aug 2018 16:48:13 +0200},
|
||||
biburl = {https://dblp.org/rec/journals/corr/LinMBHPRDZ14.bib},
|
||||
bibsource = {dblp computer science bibliography, https://dblp.org}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,80 +0,0 @@
|
|||
mindspore.dataset.DBpediaDataset
|
||||
================================
|
||||
|
||||
.. py:class:: mindspore.dataset.DBpediaDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析DBpedia数据集的源数据集。
|
||||
|
||||
生成的数据集有三列 `[class, title, content]` ,三列的数据类型均为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test'或'all'。
|
||||
'train'将读取560,000个训练样本,'test'将读取70,000个测试样本中,'all'将读取所有63万个样本。默认值:None,读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取所有样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 参数所指向的文件目录不存在或缺少数据集文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
**关于DBpedia数据集:**
|
||||
|
||||
DBpedia数据集包括14个类,超过63万个文本样本,train.csv中有56万样本,test.csv中有7万测试样本。
|
||||
14个不同的类别分别是:公司、教育学院、艺术家、运动员、文员,交通,建筑,自然场所,村庄,动物,植物,专辑,电影,书面工作。
|
||||
|
||||
以下是原始DBpedia数据集结构。
|
||||
可以将数据集文件解压缩到此目录结构中,并通过Mindspore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── dbpedia_dataset_dir
|
||||
├── train.csv
|
||||
├── test.csv
|
||||
├── classes.txt
|
||||
└── readme.txt
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{DBpedia,
|
||||
title = {DBPedia Ontology Classification Dataset},
|
||||
author = {Jens Lehmann, Robert Isele, Max Jakob, Anja Jentzsch, Dimitris Kontokostas,
|
||||
Pablo N. Mendes, Sebastian Hellmann, Mohamed Morsey, Patrick van Kleef,
|
||||
Sören Auer, Christian Bizer},
|
||||
year = {2015},
|
||||
howpublished = {http://dbpedia.org}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -20,7 +20,7 @@ mindspore.dataset.DIV2KDataset
|
|||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
|
@ -72,6 +72,8 @@ mindspore.dataset.DIV2KDataset
|
|||
|
||||
您可以解压缩原始DIV2K数据集文件到如下目录结构,并通过MindSpore的API进行读取。
|
||||
|
||||
以训练数据集作为例子。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
|
|
|
@ -8,7 +8,7 @@ mindspore.dataset.DSCallback
|
|||
用户可通过 `ds_run_context` 获取数据处理管道相关信息,包括 `cur_epoch_num` (当前epoch数)、 `cur_step_num_in_epoch` (当前epoch的step数)、 `cur_step_num` (当前step数)。
|
||||
|
||||
参数:
|
||||
- **step_size** (int, optional) - 定义相邻的 `ds_step_begin`/`ds_step_end` 调用之间相隔的step数,默认值:1,表示每个step都会调用。
|
||||
- **step_size** (int, 可选) - 定义相邻的 `ds_step_begin`/`ds_step_end` 调用之间相隔的step数,默认值:1,表示每个step都会调用。
|
||||
|
||||
.. py:method:: ds_begin(ds_run_context)
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
.. py:method:: build_sentencepiece_vocab(columns, vocab_size, character_coverage, model_type, params)
|
||||
|
||||
迭代源数据集对象获取数据并构建SentencePiece词汇表。
|
||||
源数据集要求的是文本类数据集。
|
||||
|
||||
参数:
|
||||
- **columns** (list[str]) - 指定 `build_sentencepiece_vocab` 操作的输入列,会从该列获取数据构造词汇表。
|
||||
|
@ -17,8 +18,9 @@
|
|||
.. py:method:: build_vocab(columns, freq_range, top_k, special_tokens, special_first)
|
||||
|
||||
迭代源数据集对象获取数据并构建词汇表。
|
||||
源数据集要求的是文本类数据集。
|
||||
|
||||
收集数据集中所有的不重复单词,并返回 `top_k` 个最常见的单词组成的词汇表(如果指定了 `top_k` )。
|
||||
收集数据集中所有的不重复单词。返回 `top_k` 个最常见的单词组成的词汇表(如果指定了 `top_k` )。
|
||||
|
||||
参数:
|
||||
- **columns** (Union[str, list[str]]) - 指定 `build_vocab` 操作的输入列,会从该列获取数据构造词汇表。
|
||||
|
|
|
@ -15,10 +15,10 @@
|
|||
- **column_order** (Union[str, list[str]], 可选) - 指定传递到下一个数据集操作的数据列的顺序。如果 `input_columns` 长度不等于 `output_columns` 长度,则必须指定此参数。注意:参数的列名不限定在 `input_columns` 和 `output_columns` 中指定的列,也可以是上一个操作输出的未被处理的数据列。默认值:None,按照原输入顺序排列。
|
||||
- **num_parallel_workers** (int, 可选) - 指定map操作的多进程/多线程并发数,加快处理速度。默认值:None,将使用 `set_num_parallel_workers` 设置的并发数。
|
||||
- **python_multiprocessing** (bool, 可选) - 启用Python多进程模式加速map操作。当传入的 `operations` 计算量很大时,开启此选项可能会有较好效果。默认值:False。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **callbacks** (DSCallback, list[DSCallback], 可选) - 要调用的Dataset回调函数列表。默认值:None。
|
||||
- **max_rowsize** (int, 可选) - 指定在多进程之间复制数据时,共享内存分配的最大空间,仅当 `python_multiprocessing` 为True时,该选项有效。默认值:16,单位为MB。
|
||||
- **offload** (bool, 可选) - 是否进行异构硬件加速,详情请阅读 `数据准备异构加速 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/dataset_offload.html>`_ 。默认值:None。
|
||||
- **offload** (bool, 可选) - 是否进行异构硬件加速,详情请阅读 `数据准备异构加速 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/dataset_offload.html>`_ 。默认值:None。
|
||||
|
||||
.. note::
|
||||
- `operations` 参数接收 `TensorOperation` 类型的数据处理操作,以及用户定义的Python函数(PyFuncs)。
|
||||
|
|
|
@ -28,8 +28,8 @@
|
|||
- **drop_remainder** (bool, 可选) - 当最后一个批处理数据包含的数据条目小于 `batch_size` 时,是否将该批处理丢弃,不传递给下一个操作。默认值:False,不丢弃。
|
||||
- **num_parallel_workers** (int, 可选) - 指定 `batch` 操作的并发进程数/线程数(由参数 `python_multiprocessing` 决定当前为多进程模式或多线程模式)。
|
||||
默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **per_batch_map** (Callable[[List[numpy.ndarray], ..., List[numpy.ndarray], BatchInfo], (List[numpy.ndarray],
|
||||
..., List[numpy.ndarray])], 可选) - 可调用对象,以(list[numpy.ndarray], ..., list[numpy.ndarray], BatchInfo)作为输入参数,
|
||||
- **per_batch_map** (Callable[[List[numpy.ndarray], ..., List[numpy.ndarray], BatchInfo], (List[numpy.ndarray], ..., List[numpy.ndarray])], 可选) - 可调用对象,
|
||||
以(list[numpy.ndarray], ..., list[numpy.ndarray], BatchInfo)作为输入参数,
|
||||
处理后返回(list[numpy.ndarray], list[numpy.ndarray],...)作为新的数据列。输入参数中每个list[numpy.ndarray]代表给定数据列中的一批numpy.ndarray,
|
||||
list[numpy.ndarray]的个数应与 `input_columns` 中传入列名的数量相匹配,在返回的(list[numpy.ndarray], list[numpy.ndarray], ...)中,
|
||||
list[numpy.ndarray]的个数应与输入相同,如果输出列数与输入列数不一致,则需要指定 `output_columns`。该可调用对象的最后一个输入参数始终是BatchInfo,
|
||||
|
|
|
@ -5,16 +5,16 @@ mindspore.dataset.DatasetCache
|
|||
|
||||
创建数据缓存客户端实例。
|
||||
|
||||
关于单节点数据缓存的使用,请参阅 `单节点数据缓存教程 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。
|
||||
关于单节点数据缓存的使用,请参阅 `单节点数据缓存教程 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。
|
||||
|
||||
参数:
|
||||
- **session_id** (int) - 当前数据缓存客户端的会话ID,用户在命令行开启缓存服务端后可通过 `cache_admin -g` 获取。
|
||||
- **size** (int, optional) - 设置数据缓存服务可用的内存大小。默认值:0,表示内存使用没有限制。
|
||||
- **spilling** (bool, optional) - 如果共享内存不足,是否将溢出部分缓存到磁盘。默认值:False。
|
||||
- **hostname** (str, optional) - 数据缓存服务客户端的主机IP。默认值:None,表示使用默认主机IP 127.0.0.1。
|
||||
- **port** (int, optional) - 指定连接到数据缓存服务端的端口号。默认值:None,表示端口为50052。
|
||||
- **num_connections** (int, optional) - TCP/IP连接数量。默认值:None,表示连接数量为12。
|
||||
- **prefetch_size** (int, optional) - 指定缓存队列大小,使用缓存功能算子时,将直接从缓存队列中获取数据。默认值:None,表示缓存队列大小为20。
|
||||
- **size** (int, 可选) - 设置数据缓存服务可用的内存大小。默认值:0,表示内存使用没有限制。
|
||||
- **spilling** (bool, 可选) - 如果共享内存不足,是否将溢出部分缓存到磁盘。默认值:False。
|
||||
- **hostname** (str, 可选) - 数据缓存服务客户端的主机IP。默认值:None,表示使用默认主机IP 127.0.0.1。
|
||||
- **port** (int, 可选) - 指定连接到数据缓存服务端的端口号。默认值:None,表示端口为50052。
|
||||
- **num_connections** (int, 可选) - TCP/IP连接数量。默认值:None,表示连接数量为12。
|
||||
- **prefetch_size** (int, 可选) - 指定缓存队列大小,使用缓存功能算子时,将直接从缓存队列中获取数据。默认值:None,表示缓存队列大小为20。
|
||||
|
||||
.. py:method:: get_stat()
|
||||
|
||||
|
|
|
@ -1,115 +0,0 @@
|
|||
mindspore.dataset.EMnistDataset
|
||||
===============================
|
||||
|
||||
.. py:class:: mindspore.dataset.EMnistDataset(dataset_dir, name, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析EMNIST数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列: `[image, label]`。 `image` 列的数据类型为uint8。 `label` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **name** (str) - 按给定规则对数据集进行拆分,可以是'byclass'、'bymerge'、'balanced'、'letters'、'digits'或'mnist'。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为 'train'、'test' 或 'all'。
|
||||
取值为'train'时将会读取60,000个训练样本,取值为'test'时将会读取10,000个测试样本,取值为'all'时将会读取全部70,000个样本。默认值:None,读取全部样本图片。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于EMNIST数据集:**
|
||||
|
||||
EMNIST数据集由一组手写字符数字组成,源自NIST特别版数据库19,并转换为与MNIST数据集直接匹配的28x28像素图像格式和数据集结构。
|
||||
有关数据集内容和转换过程的更多信息可在 https://arxiv.org/abs/1702.05373v1 上查阅。
|
||||
|
||||
EMNIST按照不同的规则拆分成不同的子数据集的样本数和类数如下:
|
||||
|
||||
按类拆分:814,255个样本和62个样本不平衡类。
|
||||
按合并拆分:814,255个样本和47个样本不平衡类。
|
||||
平衡拆分:131,600个样本和47个样本平衡类。
|
||||
按字母拆分:145,600个样本和26个样本平衡类。
|
||||
按数字拆分:280,000个样本和10个样本平衡类。
|
||||
MNIST: 70,000个样本符和10个样本平衡类。
|
||||
|
||||
以下是原始EMNIST数据集结构。
|
||||
可以将数据集文件解压缩到此目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── mnist_dataset_dir
|
||||
├── emnist-mnist-train-images-idx3-ubyte
|
||||
├── emnist-mnist-train-labels-idx1-ubyte
|
||||
├── emnist-mnist-test-images-idx3-ubyte
|
||||
├── emnist-mnist-test-labels-idx1-ubyte
|
||||
├── ...
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{cohen_afshar_tapson_schaik_2017,
|
||||
title = {EMNIST: Extending MNIST to handwritten letters},
|
||||
DOI = {10.1109/ijcnn.2017.7966217},
|
||||
journal = {2017 International Joint Conference on Neural Networks (IJCNN)},
|
||||
author = {Cohen, Gregory and Afshar, Saeed and Tapson, Jonathan and Schaik, Andre Van},
|
||||
year = {2017},
|
||||
howpublished = {https://www.westernsydney.edu.au/icns/reproducible_research/
|
||||
publication_support_materials/emnist}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,69 +0,0 @@
|
|||
mindspore.dataset.EnWik9Dataset
|
||||
===============================
|
||||
|
||||
.. py:class:: mindspore.dataset.EnWik9Dataset(dataset_dir, num_samples=None, num_parallel_workers=None, shuffle=True, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析EnWik9数据集的源数据集。
|
||||
|
||||
生成的数据集有一列 `[text]` ,数据类型为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。
|
||||
对于Polarity数据集,'train'将读取360万个训练样本,'test'将读取40万个测试样本,'all'将读取所有400万个样本。
|
||||
对于Full数据集,'train'将读取300万个训练样本,'test'将读取65万个测试样本,'all'将读取所有365万个样本。默认值:None,读取所有样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:True。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
**关于EnWik9数据集:**
|
||||
|
||||
EnWik9的数据是一系列UTF-8编码的XML,主要由英文文本组成。数据集包含243,426篇文章标题,其中85,560个被重定向以修复丢失的网页链接,其余是常规文章。
|
||||
|
||||
数据是UTF-8格式,所有字符都在U'0000到U'10FFFF范围内,有效编码为1到4字节。字节值0xC0、0xC1和0xF5-0xFF从未出现。此外,在维基百科转储中,除了0x09(制表符)和0x0A(换行符)外,没有范围为0x00-0x1F的控制字符。
|
||||
断行符只出现在段落边界上,因此整体是有语义目的。
|
||||
|
||||
可以将数据集文件解压缩到以下目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── EnWik9
|
||||
├── enwik9
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@NetworkResource{Hutter_prize,
|
||||
author = {English Wikipedia},
|
||||
url = "https://cs.fit.edu/~mmahoney/compression/textdata.html",
|
||||
month = {March},
|
||||
year = {2006}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,75 +0,0 @@
|
|||
mindspore.dataset.FakeImageDataset
|
||||
==================================
|
||||
|
||||
.. py:class:: mindspore.dataset.FakeImageDataset(num_images=1000, image_size=(224, 224, 3), num_classes=10, base_seed=0, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
生成虚假图像构建数据集。
|
||||
|
||||
生成的数据集有两列: `[image, label]`。 `image` 列的数据类型为uint8。 `label` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **num_images** (int, 可选) - 要生成的虚假图像数,默认值:1000。
|
||||
- **image_size** (tuple, 可选) - 虚假图像的尺寸,默认值:(224, 224, 3)。
|
||||
- **num_classes** (int, 可选) - 数据集的类别数,默认值:10。
|
||||
- **base_seed** (int, 可选) - 生成随机图像的随机种子,默认值:0。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,105 +0,0 @@
|
|||
mindspore.dataset.FashionMnistDataset
|
||||
=====================================
|
||||
|
||||
.. py:class:: mindspore.dataset.FashionMnistDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析Fashion-MNIST数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列: `[image, label]`。 `image` 列的数据类型为uint8。 `label` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为 'train'、'test' 或 'all'。
|
||||
取值为'train'时将会读取60,000个训练样本,取值为'test'时将会读取10,000个测试样本,取值为'all'时将会读取全部70,000个样本。默认值:None,读取全部样本图片。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于Fashion-MNIST数据集:**
|
||||
|
||||
Fashion-MNIST是网络电子商城Zalando推出的数据集,包括60,000个样本的训练集和10,000个样本的测试集。每个示例都是一个28x28灰度图像,分别与10个类的标签关联。
|
||||
Fashion-MNIST是原始MNIST数据集的变种,用于对机器学习算法进行基准测试。
|
||||
|
||||
可以将数据集文件解压缩到此目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── fashionmnist_dataset_dir
|
||||
├── t10k-images-idx3-ubyte
|
||||
├── t10k-labels-idx1-ubyte
|
||||
├── train-images-idx3-ubyte
|
||||
└── train-labels-idx1-ubyte
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@online{xiao2017/online,
|
||||
author = {Han Xiao and Kashif Rasul and Roland Vollgraf},
|
||||
title = {Fashion-MNIST: a Novel Image Dataset for Benchmarking Machine Learning Algorithms},
|
||||
date = {2017-08-28},
|
||||
year = {2017},
|
||||
eprintclass = {cs.LG},
|
||||
eprinttype = {arXiv},
|
||||
eprint = {cs.LG/1708.07747},
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,145 +0,0 @@
|
|||
mindspore.dataset.FlickrDataset
|
||||
================================
|
||||
|
||||
.. py:class:: mindspore.dataset.FlickrDataset(dataset_dir, annotation_file, num_samples=None, num_parallel_workers=None, shuffle=None, decode=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析Flickr8k和Flickr30k数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列: `[image, annotation]`。 `image` 列的数据类型为uint8。 `annotation` 列是一个包含5个标注字符的张量,如["a", "b", "c", "d", "e"]。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **annotation_file** (str) - 数据集标注JSON文件的路径。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数,默认值:使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,表2中会展示不同参数配置的预期行为。
|
||||
- **decode** (bool, 可选) - 是否对读取的图片进行解码操作,默认值:None,不解码。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,表2中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `annotation_file` 参数对应的文件不存在。
|
||||
- **ValueError** - `dataset_dir` 参数路径不存在。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于Flickr8k数据集:**
|
||||
|
||||
Flickr8k数据集由8092张彩色图像组成。Flickr8k.token.txt中有40460个标注,每张图像有5个标注。
|
||||
|
||||
可以将数据集文件解压缩到以下目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── Flickr8k
|
||||
├── Flickr8k_Dataset
|
||||
│ ├── 1000268201_693b08cb0e.jpg
|
||||
│ ├── 1001773457_577c3a7d70.jpg
|
||||
│ ├── ...
|
||||
└── Flickr8k.token.txt
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{DBLP:journals/jair/HodoshYH13,
|
||||
author = {Micah Hodosh and Peter Young and Julia Hockenmaier},
|
||||
title = {Framing Image Description as a Ranking Task: Data, Models and Evaluation Metrics},
|
||||
journal = {J. Artif. Intell. Res.},
|
||||
volume = {47},
|
||||
pages = {853--899},
|
||||
year = {2013},
|
||||
url = {https://doi.org/10.1613/jair.3994},
|
||||
doi = {10.1613/jair.3994},
|
||||
timestamp = {Mon, 21 Jan 2019 15:01:17 +0100},
|
||||
biburl = {https://dblp.org/rec/journals/jair/HodoshYH13.bib},
|
||||
bibsource = {dblp computer science bibliography, https://dblp.org}
|
||||
}
|
||||
|
||||
**关于Flickr30k数据集:**
|
||||
|
||||
Flickr30k数据集由31783张彩色图像组成。results_20130124.token中有158915个标注,每个图像有5个标注。
|
||||
|
||||
可以将数据集文件解压缩到以下目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── Flickr30k
|
||||
├── flickr30k-images
|
||||
│ ├── 1000092795.jpg
|
||||
│ ├── 10002456.jpg
|
||||
│ ├── ...
|
||||
└── results_20130124.token
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{DBLP:journals/tacl/YoungLHH14,
|
||||
author = {Peter Young and Alice Lai and Micah Hodosh and Julia Hockenmaier},
|
||||
title = {From image descriptions to visual denotations: New similarity metrics
|
||||
for semantic inference over event descriptions},
|
||||
journal = {Trans. Assoc. Comput. Linguistics},
|
||||
volume = {2},
|
||||
pages = {67--78},
|
||||
year = {2014},
|
||||
url = {https://tacl2013.cs.columbia.edu/ojs/index.php/tacl/article/view/229},
|
||||
timestamp = {Wed, 17 Feb 2021 21:55:25 +0100},
|
||||
biburl = {https://dblp.org/rec/journals/tacl/YoungLHH14.bib},
|
||||
bibsource = {dblp computer science bibliography, https://dblp.org}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,114 +0,0 @@
|
|||
mindspore.dataset.Flowers102Dataset
|
||||
===================================
|
||||
|
||||
.. py:class:: mindspore.dataset.Flowers102Dataset(dataset_dir, task='Classification', usage='all', num_samples=None, num_parallel_workers=1, shuffle=None, decode=False, sampler=None, num_shards=None, shard_id=None)
|
||||
|
||||
读取和解析Flowers102数据集的源文件构建数据集。
|
||||
|
||||
根据给定的 `task` 配置,生成数据集具有不同的输出列:
|
||||
|
||||
- `task` = 'Classification',输出列: `[image, dtype=uint8]` , `[label, dtype=uint32]` 。
|
||||
- `task` = 'Segmentation',输出列: `[image, dtype=uint8]` , `[segmentation, dtype=uint8]` , `[label, dtype=uint32]`。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录的路径。
|
||||
- **task** (str, 可选) - 指定读取数据的任务类型,支持'Classification'和'Segmentation'。默认值:'Classification'。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','valid','test'或'all'。默认值:'all',读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,所有图像样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **decode** (bool, 可选) - 是否对读取的图片进行解码操作,默认值:False,不解码。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于Flowers102数据集:**
|
||||
|
||||
Flowers102数据集由102个花类别组成,每个类由40到258张图像组成,这些花常见于英国。
|
||||
|
||||
以下是原始的Flowers102数据集结构。
|
||||
可以将数据集文件解压缩到此目录结构中,并通过MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── flowes102_dataset_dir
|
||||
├── imagelabels.mat
|
||||
├── setid.mat
|
||||
├── jpg
|
||||
├── image_00001.jpg
|
||||
├── image_00002.jpg
|
||||
├── ...
|
||||
├── segmim
|
||||
├── segmim_00001.jpg
|
||||
├── segmim_00002.jpg
|
||||
├── ...
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@InProceedings{Nilsback08,
|
||||
author = "Maria-Elena Nilsback and Andrew Zisserman",
|
||||
title = "Automated Flower Classification over a Large Number of Classes",
|
||||
booktitle = "Indian Conference on Computer Vision, Graphics and Image Processing",
|
||||
month = "Dec",
|
||||
year = "2008",
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,90 +1,90 @@
|
|||
mindspore.dataset.GeneratorDataset
|
||||
===================================
|
||||
|
||||
.. py:class:: mindspore.dataset.GeneratorDataset(source, column_names=None, column_types=None, schema=None, num_samples=None, num_parallel_workers=1, shuffle=None, sampler=None, num_shards=None, shard_id=None, python_multiprocessing=True, max_rowsize=6)
|
||||
|
||||
自定义Python数据源,通过迭代该数据源构造数据集。生成的数据集的列名和列类型取决于用户定义的Python数据源。
|
||||
|
||||
参数:
|
||||
- **source** (Union[Callable, Iterable, Random Accessible]) - 一个Python的可调用对象,可以是可迭代的Python对象,或支持随机访问的Python对象。
|
||||
|
||||
- 如果 `source` 是可调用对象,要求 `source` 对象可以通过 `source().next()` 的方式返回一个由NumPy数组构成的元组。
|
||||
- 如果 `source` 是可迭代对象,要求 `source` 对象通过 `iter(source).next()` 的方式返回一个由NumPy数组构成的元组。
|
||||
- 如果 `source` 是支持随机访问的对象,要求 `source` 对象通过 `source[idx]` 的方式返回一个由NumPy数组构成的元组。
|
||||
- **column_names** (Union[str, list[str]],可选) - 指定数据集生成的列名,默认值:None,不指定。用户可以通过此参数或 `schema` 参数指定列名。
|
||||
- **column_types** (list[mindspore.dtype],可选) - 指定生成数据集各个数据列的数据类型,默认值:None,不指定。
|
||||
如果未指定该参数,则自动推断类型;如果指定了该参数,将在数据输出时做类型匹配检查。
|
||||
- **schema** (Union[Schema, str],可选) - 读取模式策略,用于指定读取数据列的数据类型、数据维度等信息。
|
||||
支持传入JSON文件路径或 mindspore.dataset.Schema 构造的对象。默认值:None,不指定。
|
||||
用户可以通过提供 `column_names` 或 `schema` 指定数据集的列名,但如果同时指定两者,则将优先从 `schema` 中获取列名信息。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,默认值:None,读取全部样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作进程数/线程数(由参数 `python_multiprocessing` 决定当前为多进程模式或多线程模式),默认值:1。
|
||||
- **shuffle** (bool,可选) - 是否混洗数据集。只有输入的 `source` 参数带有可随机访问属性(`__getitem__`)时,才可以指定该参数。默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **sampler** (Union[Sampler, Iterable],可选) - 指定从数据集中选取样本的采样器。只有输入的 `source` 参数带有可随机访问属性(`__getitem__`)时,才可以指定该参数。默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **python_multiprocessing** (bool,可选) - 启用Python多进程模式加速运算,默认值:True。当传入 `source` 的Python对象的计算量很大时,开启此选项可能会有较好效果。
|
||||
- **max_rowsize** (int, 可选) - 指定在多进程之间复制数据时,共享内存分配的最大空间,默认值:6,单位为MB。仅当参数 `python_multiprocessing` 设为True时,此参数才会生效。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - Python对象 `source` 在执行期间引发异常。
|
||||
- **RuntimeError** - `column_names` 参数指定的列名数量与 `source` 参数输出的数据数量不匹配。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过最大线程数。
|
||||
- **ValueError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **ValueError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **ValueError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **ValueError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note::
|
||||
- `source` 参数接收用户自定义的Python函数(PyFuncs),不要将 `mindspore.nn` 和 `mindspore.ops` 目录下或其他的网络计算算子添加
|
||||
到 `source` 中。
|
||||
- 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
||||
mindspore.dataset.GeneratorDataset
|
||||
===================================
|
||||
|
||||
.. py:class:: mindspore.dataset.GeneratorDataset(source, column_names=None, column_types=None, schema=None, num_samples=None, num_parallel_workers=1, shuffle=None, sampler=None, num_shards=None, shard_id=None, python_multiprocessing=True, max_rowsize=6)
|
||||
|
||||
自定义Python数据源,通过迭代该数据源构造数据集。生成的数据集的列名和列类型取决于用户定义的Python数据源。
|
||||
|
||||
参数:
|
||||
- **source** (Union[Callable, Iterable, Random Accessible]) - 一个Python的可调用对象,可以是可迭代的Python对象,或支持随机访问的Python对象。
|
||||
|
||||
- 如果 `source` 是可调用对象,要求 `source` 对象可以通过 `source().next()` 的方式返回一个由NumPy数组构成的元组。
|
||||
- 如果 `source` 是可迭代对象,要求 `source` 对象通过 `iter(source).next()` 的方式返回一个由NumPy数组构成的元组。
|
||||
- 如果 `source` 是支持随机访问的对象,要求 `source` 对象通过 `source[idx]` 的方式返回一个由NumPy数组构成的元组。
|
||||
- **column_names** (Union[str, list[str]],可选) - 指定数据集生成的列名,默认值:None,不指定。用户可以通过此参数或 `schema` 参数指定列名。
|
||||
- **column_types** (list[mindspore.dtype],可选) - 指定生成数据集各个数据列的数据类型,默认值:None,不指定。
|
||||
如果未指定该参数,则自动推断类型;如果指定了该参数,将在数据输出时做类型匹配检查。
|
||||
- **schema** (Union[Schema, str],可选) - 读取模式策略,用于指定读取数据列的数据类型、数据维度等信息。
|
||||
支持传入JSON文件路径或 mindspore.dataset.Schema 构造的对象。默认值:None,不指定。
|
||||
用户可以通过提供 `column_names` 或 `schema` 指定数据集的列名,但如果同时指定两者,则将优先从 `schema` 中获取列名信息。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,默认值:None,读取全部样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作进程数/线程数(由参数 `python_multiprocessing` 决定当前为多进程模式或多线程模式),默认值:1。
|
||||
- **shuffle** (bool,可选) - 是否混洗数据集。只有输入的 `source` 参数带有可随机访问属性(`__getitem__`)时,才可以指定该参数。默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **sampler** (Union[Sampler, Iterable],可选) - 指定从数据集中选取样本的采样器。只有输入的 `source` 参数带有可随机访问属性(`__getitem__`)时,才可以指定该参数。默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **python_multiprocessing** (bool,可选) - 启用Python多进程模式加速运算,默认值:True。当传入 `source` 的Python对象的计算量很大时,开启此选项可能会有较好效果。
|
||||
- **max_rowsize** (int, 可选) - 指定在多进程之间复制数据时,共享内存分配的最大空间,默认值:6,单位为MB。仅当参数 `python_multiprocessing` 设为True时,此参数才会生效。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - Python对象 `source` 在执行期间引发异常。
|
||||
- **RuntimeError** - `column_names` 参数指定的列名数量与 `source` 参数输出的数据数量不匹配。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过最大线程数。
|
||||
- **ValueError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **ValueError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **ValueError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **ValueError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note::
|
||||
- `source` 参数接收用户自定义的Python函数(PyFuncs),不要将 `mindspore.nn` 和 `mindspore.ops` 目录下或其他的网络计算算子添加
|
||||
到 `source` 中。
|
||||
- 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
||||
|
|
|
@ -44,7 +44,7 @@ mindspore.dataset.Graph
|
|||
获取图的所有边。
|
||||
|
||||
参数:
|
||||
- **edge_type** (str) - 指定边的类型,Graph初始化未指定 `edge_type` 时,默认值为'0'。详见 `加载图数据集 <https://www.mindspore.cn/tutorials/zh-CN/master/advanced/dataset/augment_graph_data.html>`_ 。
|
||||
- **edge_type** (str) - 指定边的类型,Graph初始化未指定 `edge_type` 时,默认值为'0'。详见 `加载图数据集 <https://www.mindspore.cn/tutorials/zh-CN/r1.10/advanced/dataset/augment_graph_data.html>`_ 。
|
||||
|
||||
返回:
|
||||
numpy.ndarray,包含边的数组。
|
||||
|
@ -157,7 +157,7 @@ mindspore.dataset.Graph
|
|||
获取图中的所有节点。
|
||||
|
||||
参数:
|
||||
- **node_type** (str) - 指定节点的类型。Graph初始化未指定 `node_type` 时,默认值为'0'。详见 `加载图数据集 <https://www.mindspore.cn/tutorials/zh-CN/master/advanced/dataset/augment_graph_data.html>`_ 。
|
||||
- **node_type** (str) - 指定节点的类型。Graph初始化未指定 `node_type` 时,默认值为'0'。详见 `加载图数据集 <https://www.mindspore.cn/tutorials/zh-CN/r1.10/advanced/dataset/augment_graph_data.html>`_ 。
|
||||
|
||||
返回:
|
||||
numpy.ndarray,包含节点的数组。
|
||||
|
|
|
@ -4,6 +4,10 @@ mindspore.dataset.GraphData
|
|||
.. py:class:: mindspore.dataset.GraphData(dataset_file, num_parallel_workers=None, working_mode='local', hostname='127.0.0.1', port=50051, num_client=1, auto_shutdown=True)
|
||||
|
||||
从共享文件或数据库中读取用于GNN训练的图数据集。
|
||||
支持读取图数据集Cora、Citeseer和PubMed。
|
||||
|
||||
关于如何将源数据集加载到mindspore中请参考 `加载图数据集 <https://www.mindspore.cn/tutorials/zh-CN/r1.10/advanced/dataset/augment_graph_data.html>`_。
|
||||
|
||||
|
||||
参数:
|
||||
- **dataset_file** (str) - 数据集文件路径。
|
||||
|
@ -32,7 +36,7 @@ mindspore.dataset.GraphData
|
|||
获取图的所有边。
|
||||
|
||||
参数:
|
||||
- **edge_type** (int) - 指定边的类型,在数据集转换为MindRecord格式时,需要指定 `edge_type` 的值,并在此API中对应使用。详见 `加载图数据集 <https://www.mindspore.cn/tutorials/zh-CN/master/advanced/dataset/augment_graph_data.html>`_ 。
|
||||
- **edge_type** (int) - 指定边的类型,在数据集转换为MindRecord格式时,需要指定 `edge_type` 的值,并在此API中对应使用。详见 `加载图数据集 <https://www.mindspore.cn/tutorials/zh-CN/r1.10/advanced/dataset/augment_graph_data.html>`_ 。
|
||||
|
||||
返回:
|
||||
numpy.ndarray,包含边的数组。
|
||||
|
@ -145,7 +149,7 @@ mindspore.dataset.GraphData
|
|||
获取图中的所有节点。
|
||||
|
||||
参数:
|
||||
- **node_type** (int) - 指定节点的类型。在数据集转换为MindRecord格式时,需要指定 `node_type` 的值,并在此API中对应使用。详见 `加载图数据集 <https://www.mindspore.cn/tutorials/zh-CN/master/advanced/dataset/augment_graph_data.html>`_ 。
|
||||
- **node_type** (int) - 指定节点的类型。在数据集转换为MindRecord格式时,需要指定 `node_type` 的值,并在此API中对应使用。详见 `加载图数据集 <https://www.mindspore.cn/tutorials/zh-CN/r1.10/advanced/dataset/augment_graph_data.html>`_ 。
|
||||
|
||||
返回:
|
||||
numpy.ndarray,包含节点的数组。
|
||||
|
|
|
@ -1,135 +0,0 @@
|
|||
mindspore.dataset.IMDBDataset
|
||||
=============================
|
||||
|
||||
.. py:class:: mindspore.dataset.IMDBDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析互联网电影数据库(IMDb)的源数据集。
|
||||
|
||||
生成的数据集有两列 `[text, label]` , `text` 列的数据类型是string。 `label` 列的数据类型是uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test'或'all'。默认值:None,读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。
|
||||
对于Polarity数据集,'train'将读取360万个训练样本,'test'将读取40万个测试样本,'all'将读取所有400万个样本。
|
||||
对于Full数据集,'train'将读取300万个训练样本,'test'将读取65万个测试样本,'all'将读取所有365万个样本。默认值:None,读取所有样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 参数所指向的文件目录不存在或缺少数据集文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于IMDB数据集:**
|
||||
|
||||
IMDB数据集包含来自互联网电影数据库(IMDB)的50000条高度两极分化的评论。
|
||||
数据集分为25,000条用于训练的评论和25,000条用于测试的评论,训练集和测试集都包含50%的积极评论和50%的消极评论。
|
||||
训练标签和测试标签分别是0和1,其中0代表负样本,1代表正样本。
|
||||
|
||||
可以将数据集文件解压缩到此目录结构中,并通过MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── imdb_dataset_directory
|
||||
├── train
|
||||
│ ├── pos
|
||||
│ │ ├── 0_9.txt
|
||||
│ │ ├── 1_7.txt
|
||||
│ │ ├── ...
|
||||
│ ├── neg
|
||||
│ │ ├── 0_3.txt
|
||||
│ │ ├── 1_1.txt
|
||||
│ │ ├── ...
|
||||
├── test
|
||||
│ ├── pos
|
||||
│ │ ├── 0_10.txt
|
||||
│ │ ├── 1_10.txt
|
||||
│ │ ├── ...
|
||||
│ ├── neg
|
||||
│ │ ├── 0_2.txt
|
||||
│ │ ├── 1_3.txt
|
||||
│ │ ├── ...
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@InProceedings{maas-EtAl:2011:ACL-HLT2011,
|
||||
author = {Maas, Andrew L. and Daly, Raymond E. and Pham, Peter T. and Huang, Dan
|
||||
and Ng, Andrew Y. and Potts, Christopher},
|
||||
title = {Learning Word Vectors for Sentiment Analysis},
|
||||
booktitle = {Proceedings of the 49th Annual Meeting of the Association for Computational Linguistics:
|
||||
Human Language Technologies},
|
||||
month = {June},
|
||||
year = {2011},
|
||||
address = {Portland, Oregon, USA},
|
||||
publisher = {Association for Computational Linguistics},
|
||||
pages = {142--150},
|
||||
url = {http://www.aclweb.org/anthology/P11-1015}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,104 +0,0 @@
|
|||
mindspore.dataset.IWSLT2016Dataset
|
||||
==================================
|
||||
|
||||
.. py:class:: mindspore.dataset.IWSLT2016Dataset(dataset_dir, usage=None, language_pair=None, valid_set=None, test_set=None, num_samples=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, num_parallel_workers=None, cache=None)
|
||||
|
||||
读取和解析IWSLT2016数据集的源数据集。
|
||||
|
||||
生成的数据集有两列 `[text, translation]` , `text` 列的数据类型是string。 `translation` 列的数据类型是string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','valid','test'或'all'。默认值:None,读取全部样本。
|
||||
- **language_pair** (sequence, 可选) - 包含源语言和目标语言的序列,支持的值为('en','fr')、('en','de')、('en','cs')、('en','ar')、('de','en'),('cs','en'),('ar','en'),默认值:('de','en')。
|
||||
- **valid_set** (str, 可选) - 标识验证集的字符串,支持的值为'dev2010'、'tst2010'、'tst2011'、'tst'2012,'tst2013'和'tst2014',默认值:'tst2013'。
|
||||
- **test_set** (str, 可选) - 识测试集的字符串,支持的值为'dev2010'、'tst2010'、'tst2011'、'tst'2012、'tst2013'和'tst2014',默认值:'tst2014'。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 参数所指向的文件目录不存在或缺少数据集文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
|
||||
**关于IWSLT2016数据集:**
|
||||
|
||||
IWSLT是一个专门讨论口译各个方面的重要年度科学会议。IWSLT评估活动中的MT任务被构成一个数据集,该数据集可通过wit3.fbk.eu公开获取。
|
||||
IWSLT2016数据集包括从英语到阿拉伯语、捷克、法语和德语的翻译,以及从阿拉伯语、捷克、法语和德语到英语的翻译。
|
||||
|
||||
可以将原始IWSLT2016数据集文件解压缩到此目录结构中,并由MindSpore的API读取。解压后,还需要将要读取的数据集解压到指定文件夹中。例如,如果要读取de-en的数据集,则需要解压缩de/en目录下的tgz文件,数据集位于解压缩文件夹中。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── iwslt2016_dataset_directory
|
||||
├── subeval_files
|
||||
└── texts
|
||||
├── ar
|
||||
│ └── en
|
||||
│ └── ar-en
|
||||
├── cs
|
||||
│ └── en
|
||||
│ └── cs-en
|
||||
├── de
|
||||
│ └── en
|
||||
│ └── de-en
|
||||
│ ├── IWSLT16.TED.dev2010.de-en.de.xml
|
||||
│ ├── train.tags.de-en.de
|
||||
│ ├── ...
|
||||
├── en
|
||||
│ ├── ar
|
||||
│ │ └── en-ar
|
||||
│ ├── cs
|
||||
│ │ └── en-cs
|
||||
│ ├── de
|
||||
│ │ └── en-de
|
||||
│ └── fr
|
||||
│ └── en-fr
|
||||
└── fr
|
||||
└── en
|
||||
└── fr-en
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@inproceedings{cettoloEtAl:EAMT2012,
|
||||
Address = {Trento, Italy},
|
||||
Author = {Mauro Cettolo and Christian Girardi and Marcello Federico},
|
||||
Booktitle = {Proceedings of the 16$^{th}$ Conference of the European Association for Machine Translation
|
||||
(EAMT)},
|
||||
Date = {28-30},
|
||||
Month = {May},
|
||||
Pages = {261--268},
|
||||
Title = {WIT$^3$: Web Inventory of Transcribed and Translated Talks},
|
||||
Year = {2012}}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,102 +0,0 @@
|
|||
mindspore.dataset.IWSLT2017Dataset
|
||||
==================================
|
||||
|
||||
.. py:class:: mindspore.dataset.IWSLT2017Dataset(dataset_dir, usage=None, language_pair=None, num_samples=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, num_parallel_workers=None, cache=None)
|
||||
|
||||
读取和解析IWSLT2017数据集的源数据集。
|
||||
|
||||
生成的数据集有两列 `[text, translation]` , `text` 列的数据类型是string。 `translation` 列的数据类型是string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','valid','test'或'all'。默认值:None,读取全部样本。
|
||||
- **language_pair** (sequence, 可选) - 包含源语和目标语的语言列表,支持的语言对有('en','nl')、('en','de')、('en','it')、('en','ro')、('nl','en','de')、('nl','it')、('nl','ro')、('de','en')、('de','nl')、('de','it','it','en')、('it','nl')、('it','de')、('it','ro')、('ro','en')、('ro','nl')、('ro','de')、('ro','it'),默认值:('de','en')。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 参数所指向的文件目录不存在或缺少数据集文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
|
||||
**关于IWSLT2016数据集:**
|
||||
|
||||
IWSLT是一个专门讨论口译各个方面的重要年度科学会议。IWSLT评估活动中的MT任务被构成一个数据集,该数据集可通过wit3.fbk.eu公开获取。
|
||||
IWSLT2017数据集中有德语、英语、意大利语、荷兰语和罗马尼亚语,数据集包括其中任何两种语言的翻译。
|
||||
|
||||
可以将原始IWSLT2017数据集文件解压缩到此目录结构中,并由MindSpore的API读取。解压后,还需要将要读取的数据集解压到指定文件夹中。例如,如果要读取de-en的数据集,则需要解压缩de/en目录下的tgz文件,数据集位于解压缩文件夹中。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── iwslt2017_dataset_directory
|
||||
├── subeval_files
|
||||
└── texts
|
||||
├── ar
|
||||
│ └── en
|
||||
│ └── ar-en
|
||||
├── cs
|
||||
│ └── en
|
||||
│ └── cs-en
|
||||
├── de
|
||||
│ └── en
|
||||
│ └── de-en
|
||||
│ ├── IWSLT16.TED.dev2010.de-en.de.xml
|
||||
│ ├── train.tags.de-en.de
|
||||
│ ├── ...
|
||||
├── en
|
||||
│ ├── ar
|
||||
│ │ └── en-ar
|
||||
│ ├── cs
|
||||
│ │ └── en-cs
|
||||
│ ├── de
|
||||
│ │ └── en-de
|
||||
│ └── fr
|
||||
│ └── en-fr
|
||||
└── fr
|
||||
└── en
|
||||
└── fr-en
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@inproceedings{cettoloEtAl:EAMT2012,
|
||||
Address = {Trento, Italy},
|
||||
Author = {Mauro Cettolo and Christian Girardi and Marcello Federico},
|
||||
Booktitle = {Proceedings of the 16$^{th}$ Conference of the European Association for Machine Translation
|
||||
(EAMT)},
|
||||
Date = {28-30},
|
||||
Month = {May},
|
||||
Pages = {261--268},
|
||||
Title = {WIT$^3$: Web Inventory of Transcribed and Translated Talks},
|
||||
Year = {2012}}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,103 +1,103 @@
|
|||
mindspore.dataset.ImageFolderDataset
|
||||
=====================================
|
||||
|
||||
.. py:class:: mindspore.dataset.ImageFolderDataset(dataset_dir, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, extensions=None, class_indexing=None, decode=False, num_shards=None, shard_id=None, cache=None, decrypt=None)
|
||||
|
||||
从树状结构的文件目录中读取图片构建源数据集,同一个文件夹中的所有图片将被分配相同的label。
|
||||
|
||||
生成的数据集有两列:`[image, label]`。`image` 列的数据类型为uint8,`label` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录的路径。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **extensions** (list[str], 可选) - 指定文件的扩展名,仅读取与指定扩展名匹配的文件到数据集中,默认值:None。
|
||||
- **class_indexing** (dict, 可选) - 指定文件夹名称到label索引的映射,要求映射规则为string到int。文件夹名称将按字母顺序排列,索引值从0开始,并且要求每个文件夹名称对应的索引值唯一。默认值:None,不指定。
|
||||
- **decode** (bool, 可选) - 是否对读取的图片进行解码操作,默认值:False,不解码。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **decrypt** (callable, 可选) - 图像解密函数,接受加密的图片路径并返回bytes类型的解密数据。默认值:None,不进行解密。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 不包含任何数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **RuntimeError** - `class_indexing` 参数的类型不是dict。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note::
|
||||
- 如果 `decode` 参数的值为False,则得到的 `image` 列的shape为[undecoded_image_size],如果为True则 `image` 列的shape为[H,W,C]。
|
||||
- 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于ImageFolderDataset:**
|
||||
|
||||
您可以将图片数据文件构建成如下目录结构,并通过MindSpore的API进行读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── image_folder_dataset_directory
|
||||
├── class1
|
||||
│ ├── 000000000001.jpg
|
||||
│ ├── 000000000002.jpg
|
||||
│ ├── ...
|
||||
├── class2
|
||||
│ ├── 000000000001.jpg
|
||||
│ ├── 000000000002.jpg
|
||||
│ ├── ...
|
||||
├── class3
|
||||
│ ├── 000000000001.jpg
|
||||
│ ├── 000000000002.jpg
|
||||
│ ├── ...
|
||||
├── classN
|
||||
├── ...
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
||||
mindspore.dataset.ImageFolderDataset
|
||||
=====================================
|
||||
|
||||
.. py:class:: mindspore.dataset.ImageFolderDataset(dataset_dir, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, extensions=None, class_indexing=None, decode=False, num_shards=None, shard_id=None, cache=None, decrypt=None)
|
||||
|
||||
从树状结构的文件目录中读取图片构建源数据集,同一个文件夹中的所有图片将被分配相同的label。
|
||||
|
||||
生成的数据集有两列:`[image, label]`。`image` 列的数据类型为uint8,`label` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录的路径。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **extensions** (list[str], 可选) - 指定文件的扩展名,仅读取与指定扩展名匹配的文件到数据集中,默认值:None。
|
||||
- **class_indexing** (dict, 可选) - 指定文件夹名称到label索引的映射,要求映射规则为string到int。文件夹名称将按字母顺序排列,索引值从0开始,并且要求每个文件夹名称对应的索引值唯一。默认值:None,不指定。
|
||||
- **decode** (bool, 可选) - 是否对读取的图片进行解码操作,默认值:False,不解码。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **decrypt** (callable, 可选) - 图像解密函数,接受加密的图片路径并返回bytes类型的解密数据。默认值:None,不进行解密。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 不包含任何数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **RuntimeError** - `class_indexing` 参数的类型不是dict。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note::
|
||||
- 如果 `decode` 参数的值为False,则得到的 `image` 列的shape为[undecoded_image_size],如果为True则 `image` 列的shape为[H,W,C]。
|
||||
- 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于ImageFolderDataset:**
|
||||
|
||||
您可以将图片数据文件构建成如下目录结构,并通过MindSpore的API进行读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── image_folder_dataset_directory
|
||||
├── class1
|
||||
│ ├── 000000000001.jpg
|
||||
│ ├── 000000000002.jpg
|
||||
│ ├── ...
|
||||
├── class2
|
||||
│ ├── 000000000001.jpg
|
||||
│ ├── 000000000002.jpg
|
||||
│ ├── ...
|
||||
├── class3
|
||||
│ ├── 000000000001.jpg
|
||||
│ ├── 000000000002.jpg
|
||||
│ ├── ...
|
||||
├── classN
|
||||
├── ...
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
||||
|
|
|
@ -1,54 +1,54 @@
|
|||
mindspore.dataset.InMemoryGraphDataset
|
||||
========================================
|
||||
|
||||
.. py:class:: mindspore.dataset.InMemoryGraphDataset(data_dir, save_dir="./processed", column_names="graph", num_samples=None, num_parallel_workers=1, shuffle=None, num_shards=None, shard_id=None, python_multiprocessing=True, max_rowsize=6)
|
||||
|
||||
用于将图数据加载到内存中的Dataset基类。
|
||||
|
||||
建议通过继承这个基类来实现自定义Dataset,并重写相应的方法,如 `process` 、 `save` 和 `load` ,可参考 `ArgoverseDataset` 源码。自定义Dataset的初始化过程如下,首先检查在给定的 `data_dir` 中是否已经有处理好的数据,如果是则调用 `load` 方法直接加载它,否则将调用 `process` 方法创建图,并调用 `save` 方法将图保存到 `save_dir`。
|
||||
|
||||
可以访问所创建dataset中的图并使用,例如 `graphs = my_dataset.graphs`,也可以迭代dataset对象如 `my_dataset.create_tuple_iterator()` 来获取数据(这时需要实现 `__getitem__` 和 `__len__`)方法,具体请参考以下示例。注意:内部逻辑指定了 `__new__` 阶段会重新初始化 `__init__` ,如果自定义图实现了 `__new__` 方法,该方法将失效。
|
||||
|
||||
参数:
|
||||
- **data_dir** (str) - 加载数据集的目录,这里包含原始格式的数据,并将在 `process` 方法中被加载。
|
||||
- **save_dir** (str) - 保存处理后得到的数据集的相对目录,该目录位于 `data_dir` 下面,默认值:"./processed"。
|
||||
- **column_names** (Union[str, list[str]],可选) - dataset包含的单个列名或多个列名组成的列表,默认值:'Graph'。当实现类似 `__getitem__` 等方法时,列名的数量应该等于该方法中返回数据的条数。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,默认值:None,读取全部样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作进程数/线程数(由参数 `python_multiprocessing` 决定当前为多进程模式或多线程模式),默认值:1。
|
||||
- **shuffle** (bool,可选) - 是否混洗数据集。当实现的Dataset带有可随机访问属性( `__getitem__` )时,才可以指定该参数。默认值:None。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **python_multiprocessing** (bool,可选) - 启用Python多进程模式加速运算,默认值:True。当传入 `source` 的Python对象的计算量很大时,开启此选项可能会有较好效果。
|
||||
- **max_rowsize** (int, 可选) - 指定在多进程之间复制数据时,共享内存分配的最大空间,默认值:6,单位为MB。仅当参数 `python_multiprocessing` 设为True时,此参数才会生效。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. py:method:: load()
|
||||
|
||||
从给定(处理好的)路径加载数据,也可以在自己实现的Dataset类中实现这个方法。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. py:method:: process()
|
||||
|
||||
与原始数据集相关的处理方法,建议在自定义的Dataset中重写此方法。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. py:method:: save()
|
||||
|
||||
将经过 `process` 函数处理后的数据以 numpy.npz 格式保存到磁盘中,也可以在自己实现的Dataset类中自己实现这个方法。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
||||
mindspore.dataset.InMemoryGraphDataset
|
||||
========================================
|
||||
|
||||
.. py:class:: mindspore.dataset.InMemoryGraphDataset(data_dir, save_dir="./processed", column_names="graph", num_samples=None, num_parallel_workers=1, shuffle=None, num_shards=None, shard_id=None, python_multiprocessing=True, max_rowsize=6)
|
||||
|
||||
用于将图数据加载到内存中的Dataset基类。
|
||||
|
||||
建议通过继承这个基类来实现自定义Dataset,并重写相应的方法,如 `process` 、 `save` 和 `load` ,可参考 `ArgoverseDataset` 源码。自定义Dataset的初始化过程如下,首先检查在给定的 `data_dir` 中是否已经有处理好的数据。如果是则调用 `load` 方法直接加载它,否则将调用 `process` 方法创建图,并调用 `save` 方法将图保存到 `save_dir`。
|
||||
|
||||
可以访问所创建dataset中的图并使用,例如 `graphs = my_dataset.graphs`,也可以迭代dataset对象如 `my_dataset.create_tuple_iterator()` 来获取数据(这时需要实现 `__getitem__` 和 `__len__`)方法,具体请参考以下示例。注意:内部逻辑指定了 `__new__` 阶段会重新初始化 `__init__` ,如果自定义图实现了 `__new__` 方法,该方法将失效。
|
||||
|
||||
参数:
|
||||
- **data_dir** (str) - 加载数据集的目录,这里包含原始格式的数据,并将在 `process` 方法中被加载。
|
||||
- **save_dir** (str) - 保存处理后得到的数据集的相对目录,该目录位于 `data_dir` 下面,默认值:"./processed"。
|
||||
- **column_names** (Union[str, list[str]],可选) - dataset包含的单个列名或多个列名组成的列表,默认值:'Graph'。当实现类似 `__getitem__` 等方法时,列名的数量应该等于该方法中返回数据的条数。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,默认值:None,读取全部样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作进程数/线程数(由参数 `python_multiprocessing` 决定当前为多进程模式或多线程模式),默认值:1。
|
||||
- **shuffle** (bool,可选) - 是否混洗数据集。当实现的Dataset带有可随机访问属性( `__getitem__` )时,才可以指定该参数。默认值:None。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **python_multiprocessing** (bool,可选) - 启用Python多进程模式加速运算,默认值:True。当传入 `source` 的Python对象的计算量很大时,开启此选项可能会有较好效果。
|
||||
- **max_rowsize** (int, 可选) - 指定在多进程之间复制数据时,共享内存分配的最大空间,默认值:6,单位为MB。仅当参数 `python_multiprocessing` 设为True时,此参数才会生效。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. py:method:: load()
|
||||
|
||||
从给定(处理好的)路径加载数据,也可以在自己实现的Dataset类中实现这个方法。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. py:method:: process()
|
||||
|
||||
与原始数据集相关的处理方法,建议在自定义的Dataset中重写此方法。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. py:method:: save()
|
||||
|
||||
将经过 `process` 函数处理后的数据以 numpy.npz 格式保存到磁盘中,也可以在自己实现的Dataset类中自己实现这个方法。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
||||
|
|
|
@ -1,104 +0,0 @@
|
|||
mindspore.dataset.KMnistDataset
|
||||
===============================
|
||||
|
||||
.. py:class:: mindspore.dataset.KMnistDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析KMNIST数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列: `[image, label]`。 `image` 列的数据类型为uint8。 `label` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为 'train'、'test' 或 'all'。
|
||||
取值为'train'时将会读取60,000个训练样本,取值为'test'时将会读取10,000个测试样本,取值为'all'时将会读取全部70,000个样本。默认值:None,读取全部样本图片。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于KMNIST数据集:**
|
||||
|
||||
KMNIST是一个数据集,改编自Kuzushiji数据集,作为MNIST数据集的替代数据集(MNIST数据集是机器学习社区中著名的数据集)。
|
||||
以下是原始KMNIST数据集结构,可以将数据集文件解压缩到此目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── kmnist_dataset_dir
|
||||
├── t10k-images-idx3-ubyte
|
||||
├── t10k-labels-idx1-ubyte
|
||||
├── train-images-idx3-ubyte
|
||||
└── train-labels-idx1-ubyte
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@online{clanuwat2018deep,
|
||||
author = {Tarin Clanuwat and Mikel Bober-Irizar and Asanobu Kitamoto and
|
||||
Alex Lamb and Kazuaki Yamamoto and David Ha},
|
||||
title = {Deep Learning for Classical Japanese Literature},
|
||||
date = {2018-12-03},
|
||||
year = {2018},
|
||||
eprintclass = {cs.CV},
|
||||
eprinttype = {arXiv},
|
||||
eprint = {cs.CV/1812.01718},
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,114 +0,0 @@
|
|||
mindspore.dataset.LJSpeechDataset
|
||||
=================================
|
||||
|
||||
.. py:class:: mindspore.dataset.LJSpeechDataset(dataset_dir, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析LJSpeech数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列: `[waveform, sample_rate, transcription, normalized_transcript]`。
|
||||
`waveform` 列的数据类型为float32, `sample_rate` 列的数据类型为int32, `transcription` 列的数据类型为string, `normalized_transcript` 列的数据类型为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本音频。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于LJSPEECH数据集:**
|
||||
|
||||
LJSPEECH是一个公共领域的语音数据集,由13,100个来自7部非小说类书籍的段落短音频片段组成。
|
||||
为每个剪辑片段都进行转录,剪辑的长度从1秒到10秒不等,总长度约为24小时。
|
||||
|
||||
这些被阅读的文本于1884年至1964年间出版,属于公共领域,这些音频由LibriVox项目于2016-17年录制。
|
||||
|
||||
以下是原始的LJSPEECH数据集结构。
|
||||
可以将数据集文件解压缩到以下目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── LJSpeech-1.1
|
||||
├── README
|
||||
├── metadata.csv
|
||||
└── wavs
|
||||
├── LJ001-0001.wav
|
||||
├── LJ001-0002.wav
|
||||
├── LJ001-0003.wav
|
||||
├── LJ001-0004.wav
|
||||
├── LJ001-0005.wav
|
||||
├── LJ001-0006.wav
|
||||
├── LJ001-0007.wav
|
||||
├── LJ001-0008.wav
|
||||
...
|
||||
├── LJ050-0277.wav
|
||||
└── LJ050-0278.wav
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@misc{lj_speech17,
|
||||
author = {Keith Ito and Linda Johnson},
|
||||
title = {The LJ Speech Dataset},
|
||||
howpublished = {url{https://keithito.com/LJ-Speech-Dataset}},
|
||||
year = 2017
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -18,7 +18,7 @@
|
|||
- **decode** (bool, 可选) - 是否对读取的图片进行解码操作,默认值:False,不解码。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_files` 路径下不包含任何数据文件。
|
||||
|
|
|
@ -20,10 +20,10 @@
|
|||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。当前此数据集仅支持以下采样器:SubsetRandomSampler、PkSampler、RandomSampler、SequentialSampler和DistributedSampler。
|
||||
- **padded_sample** (dict, 可选): 指定额外添加到数据集的样本,可用于在分布式训练时补齐分片数据,注意字典的键名需要与 `column_list` 指定的列名相同。默认值:None,不添加样本。需要与 `num_padded` 参数同时使用。
|
||||
- **padded_sample** (dict, 可选) - 指定额外添加到数据集的样本,可用于在分布式训练时补齐分片数据,注意字典的键名需要与 `column_list` 指定的列名相同。默认值:None,不添加样本。需要与 `num_padded` 参数同时使用。
|
||||
- **num_padded** (int, 可选) - 指定额外添加的数据集样本的数量。在分布式训练时可用于为数据集补齐样本,使得总样本数量可被 `num_shards` 整除。默认值:None,不添加样本。需要与 `padded_sample` 参数同时使用。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取所有样本。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **ValueError** - `dataset_files` 参数所指向的文件无效或不存在。
|
||||
|
|
|
@ -1,104 +1,104 @@
|
|||
mindspore.dataset.MnistDataset
|
||||
===============================
|
||||
|
||||
.. py:class:: mindspore.dataset.MnistDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析MNIST数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列: `[image, label]`。 `image` 列的数据类型为uint8。 `label` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为 'train'、'test' 或 'all'。
|
||||
取值为'train'时将会读取60,000个训练样本,取值为'test'时将会读取10,000个测试样本,取值为'all'时将会读取全部70,000个样本。默认值:None,读取全部样本图片。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **ValueError** - `usage` 参数取值不为'train'、'test'或'all'。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于MNIST数据集:**
|
||||
|
||||
MNIST手写数字数据集是NIST数据集的子集,共有60,000个训练样本和10,000个测试样本。
|
||||
|
||||
以下为原始MNIST数据集的结构,您可以将数据集文件解压得到如下的文件结构,并通过MindSpore的API进行读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── mnist_dataset_dir
|
||||
├── t10k-images-idx3-ubyte
|
||||
├── t10k-labels-idx1-ubyte
|
||||
├── train-images-idx3-ubyte
|
||||
└── train-labels-idx1-ubyte
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{lecun2010mnist,
|
||||
title = {MNIST handwritten digit database},
|
||||
author = {LeCun, Yann and Cortes, Corinna and Burges, CJ},
|
||||
journal = {ATT Labs [Online]},
|
||||
volume = {2},
|
||||
year = {2010},
|
||||
howpublished = {http://yann.lecun.com/exdb/mnist}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
mindspore.dataset.MnistDataset
|
||||
===============================
|
||||
|
||||
.. py:class:: mindspore.dataset.MnistDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析MNIST数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列: `[image, label]`。 `image` 列的数据类型为uint8。 `label` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为 'train'、'test' 或 'all'。
|
||||
取值为'train'时将会读取60,000个训练样本,取值为'test'时将会读取10,000个测试样本,取值为'all'时将会读取全部70,000个样本。默认值:None,读取全部样本图片。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **ValueError** - `usage` 参数取值不为'train'、'test'或'all'。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于MNIST数据集:**
|
||||
|
||||
MNIST手写数字数据集是NIST数据集的子集,共有60,000个训练样本和10,000个测试样本。此数据集是NIST数据集的子集。数字已经预先进行了尺寸归一化和中心化处理。
|
||||
|
||||
以下为原始MNIST数据集的结构,您可以将数据集文件解压得到如下的文件结构,并通过MindSpore的API进行读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── mnist_dataset_dir
|
||||
├── t10k-images-idx3-ubyte
|
||||
├── t10k-labels-idx1-ubyte
|
||||
├── train-images-idx3-ubyte
|
||||
└── train-labels-idx1-ubyte
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{lecun2010mnist,
|
||||
title = {MNIST handwritten digit database},
|
||||
author = {LeCun, Yann and Cortes, Corinna and Burges, CJ},
|
||||
journal = {ATT Labs [Online]},
|
||||
volume = {2},
|
||||
year = {2010},
|
||||
howpublished = {http://yann.lecun.com/exdb/mnist}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,79 +0,0 @@
|
|||
mindspore.dataset.PennTreebankDataset
|
||||
=====================================
|
||||
|
||||
.. py:class:: mindspore.dataset.PennTreebankDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析PennTreebank数据集的源数据集。
|
||||
|
||||
生成的数据集有一列 `[text]` ,数据类型为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test','valid'或'all'。
|
||||
取值为'train'将读取42,068个样本,'test'将读取3,370个样本,'test'将读取3,761个样本,'all'将读取所有49,199个样本。默认值:None,读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取所有样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:True。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
**关于PennTreebank数据集:**
|
||||
|
||||
Penn Treebank (PTB) 数据集,广泛用于 NLP(自然语言处理)的机器学习研究。
|
||||
PTB 不包含大写字母、数字和标点符号,其词汇表上限为10k个不重复词,与大多数现代数据集相比相对较小,可能会导致出现大量超出词汇表外的token。
|
||||
|
||||
以下是原始的PennTreebank数据集结构。
|
||||
可以将数据集文件解压缩到此目录结构中,并通过MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── PennTreebank_dataset_dir
|
||||
├── ptb.test.txt
|
||||
├── ptb.train.txt
|
||||
└── ptb.valid.txt
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@techreport{Santorini1990,
|
||||
added-at = {2014-03-26T23:25:56.000+0100},
|
||||
author = {Santorini, Beatrice},
|
||||
biburl = {https://www.bibsonomy.org/bibtex/234cdf6ddadd89376090e7dada2fc18ec/butonic},
|
||||
file = {:Santorini - Penn Treebank tag definitions.pdf:PDF},
|
||||
institution = {Department of Computer and Information Science, University of Pennsylvania},
|
||||
interhash = {818e72efd9e4b5fae3e51e88848100a0},
|
||||
intrahash = {34cdf6ddadd89376090e7dada2fc18ec},
|
||||
keywords = {dis pos tagging treebank},
|
||||
number = {MS-CIS-90-47},
|
||||
timestamp = {2014-03-26T23:25:56.000+0100},
|
||||
title = {Part-of-speech tagging guidelines for the {P}enn {T}reebank {P}roject},
|
||||
url = {ftp://ftp.cis.upenn.edu/pub/treebank/doc/tagguide.ps.gz},
|
||||
year = 1990
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,127 +0,0 @@
|
|||
mindspore.dataset.PhotoTourDataset
|
||||
==================================
|
||||
|
||||
.. py:class:: mindspore.dataset.PhotoTourDataset(dataset_dir, name, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析PhotoTour数据集的源数据集。
|
||||
|
||||
当 `usage` = 'train',生成的数据集有一列 `[image]` ,数据类型为uint8。
|
||||
当 `usage` ≠ 'train',生成的数据集有三列: `[image1, image2, matches]`。 `image1` 、 `image2` 列的数据类型为uint8。 `matches` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **name** (str) - 要加载的数据集内容名称,可以取值为'notredame', 'yosemite', 'liberty', 'notredame_harris', 'yosemite_harris' 或 'liberty_harris'。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train'或'test'。默认值:None,将被设置为'train'。
|
||||
取值为'train'时,每个 `name` 的数据集样本数分别为{'notredame': 468159, 'yosemite': 633587, 'liberty': 450092, 'liberty_harris': 379587, 'yosemite_harris': 450912, 'notredame_harris': 325295}。
|
||||
取值为'test'时,将读取100,000个测试样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取所有样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `dataset_dir` 不存在。
|
||||
- **ValueError** - `usage` 不是["train", "test"]中的任何一个。
|
||||
- **ValueError** - `name` 不是["notredame", "yosemite", "liberty","notredame_harris", "yosemite_harris", "liberty_harris"]中的任何一个。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于PhotoTour数据集:**
|
||||
|
||||
数据取自许愿池(罗马)、巴黎圣母院(巴黎)和半圆顶(美国约塞米蒂国家公园)的旅游圣地照片。
|
||||
每个数据集包括一系列相应的图像块,是通过将旅游圣地的照片中的3D点投影回到原始图像而获得的。
|
||||
|
||||
数据集由1024 x 1024位图(.bmp)图像组成,每个图像都包含16 x 16的图像修补数组。
|
||||
每个图像块都以64 x 64灰度采样,具有规范的比例和方向。有关如何确定比例和方向的详细信息,请参见论文。
|
||||
关联的元数据文件info.txt包含匹配信息。info.txt的每一行对应一个单独的图像块,图像块在每个位图图像中从左到右、从上到下顺序排列。
|
||||
info.txt每行上的第一个数字是采样该图像块的3D点ID——具有相同3D点ID的图像块从同一3D点投影(到不同的图像中)。
|
||||
info.txt中的第二个数字代表图像块是从哪个原始图像采样得到,目前未使用。
|
||||
|
||||
可以将原始PhotoTour数据集文件解压缩到此目录结构中,并通过MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── photo_tour_dataset_directory
|
||||
├── liberty/
|
||||
│ ├── info.txt // two columns: 3D_point_ID, unused
|
||||
│ ├── m50_100000_100000_0.txt // seven columns: patch_ID1, 3D_point_ID1, unused1,
|
||||
│ │ // patch_ID2, 3D_point_ID2, unused2, unused3
|
||||
│ ├── patches0000.bmp // 1024*1024 pixels, with 16 * 16 patches.
|
||||
│ ├── patches0001.bmp
|
||||
│ ├── ...
|
||||
├── yosemite/
|
||||
│ ├── ...
|
||||
├── notredame/
|
||||
│ ├── ...
|
||||
├── liberty_harris/
|
||||
│ ├── ...
|
||||
├── yosemite_harris/
|
||||
│ ├── ...
|
||||
├── notredame_harris/
|
||||
│ ├── ...
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@INPROCEEDINGS{4269996,
|
||||
author={Winder, Simon A. J. and Brown, Matthew},
|
||||
booktitle={2007 IEEE Conference on Computer Vision and Pattern Recognition},
|
||||
title={Learning Local Image Descriptors},
|
||||
year={2007},
|
||||
volume={},
|
||||
number={},
|
||||
pages={1-8},
|
||||
doi={10.1109/CVPR.2007.382971}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,121 +0,0 @@
|
|||
mindspore.dataset.Places365Dataset
|
||||
==================================
|
||||
|
||||
.. py:class:: mindspore.dataset.Places365Dataset(dataset_dir, usage=None, small=True, decode=False, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析PhotoTour数据集的源数据集。
|
||||
|
||||
生成的数据集有两列: `[image, label]`。
|
||||
`image` 列的数据类型为uint8。 `label` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 'train-standard'、'train-challenge'或'val',默认值:'train-standard'。
|
||||
- **small** (bool, 可选) - 是否使用256*256的低分辨率图像(True)或高分辨率图像(False)。默认值:False,使用低分辨率图像。
|
||||
- **decode** (bool, 可选) - 是否对读取的图片进行解码操作,默认值:False,不解码。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取所有样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
- **ValueError** - `usage` 不是['train-standard', 'train-challenge', 'val']中的任何一个。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于Places365数据集:**
|
||||
|
||||
在Places2数据库上训练的卷积神经网络(CNN)可用于场景识别,也可用于视觉识别的通用深度场景特征。
|
||||
|
||||
Places作者向公众发布了Places365-Standard数据集和Places365-Challenge数据集。
|
||||
Places365-Standard数据集是Places2数据库的核心集,该数据库已用于训练Places365-CNN。
|
||||
Places作者将在未来的Places365-Standard数据集上添加其他类型的标注。
|
||||
Places365-Challenge数据集是Places2数据库的竞赛数据集,与Places365-Standard数据集相比,该数据库有620万张额外的图像,此数据集用于2016年的Places挑战赛。
|
||||
|
||||
可以将原始的Places365数据集文件解压缩到此目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── categories_places365
|
||||
├── places365_train-standard.txt
|
||||
├── places365_train-challenge.txt
|
||||
├── val_large/
|
||||
│ ├── Places365_val_00000001.jpg
|
||||
│ ├── Places365_val_00000002.jpg
|
||||
│ ├── Places365_val_00000003.jpg
|
||||
│ ├── ...
|
||||
├── val_256/
|
||||
│ ├── ...
|
||||
├── data_large_standard/
|
||||
│ ├── ...
|
||||
├── data_256_standard/
|
||||
│ ├── ...
|
||||
├── data_large_challenge/
|
||||
│ ├── ...
|
||||
├── data_256_challenge /
|
||||
│ ├── ...
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
article{zhou2017places,
|
||||
title={Places: A 10 million Image Database for Scene Recognition},
|
||||
author={Zhou, Bolei and Lapedriza, Agata and Khosla, Aditya and Oliva, Aude and Torralba, Antonio},
|
||||
journal={IEEE Transactions on Pattern Analysis and Machine Intelligence},
|
||||
year={2017},
|
||||
publisher={IEEE}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,106 +0,0 @@
|
|||
mindspore.dataset.QMnistDataset
|
||||
===============================
|
||||
|
||||
.. py:class:: mindspore.dataset.QMnistDataset(dataset_dir, usage=None, compat=True, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析QMNIST数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列: `[image, label]`。 `image` 列的数据类型为uint8, `label` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train'、'test'、'test10k'、'test50k'、'nist'或'all',默认值:None,读取所有子集。
|
||||
- **compat** (bool, 可选) - 指定每个样本的标签是类别号(compat=True)还是完整的QMNIST信息(compat=False)。默认值:True,标签为类别号。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取所有样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于QMNIST数据集:**
|
||||
|
||||
QMNIST 数据集是从 NIST Special Database 19 中的原始数据生成的,目的是尽可能地匹配 MNIST 预处理。
|
||||
研究人员试图生成额外的 50k 类似 MNIST 数据的图像,在QMNIST论文中,作者给出了重建过程,并使用匈牙利算法来找到原始 MNIST 样本与其重建样本之间的最佳匹配。
|
||||
|
||||
以下是原始的QMNIST数据集结构。
|
||||
可以将数据集文件解压缩到此目录结构中,并通过MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── qmnist_dataset_dir
|
||||
├── qmnist-train-images-idx3-ubyte
|
||||
├── qmnist-train-labels-idx2-int
|
||||
├── qmnist-test-images-idx3-ubyte
|
||||
├── qmnist-test-labels-idx2-int
|
||||
├── xnist-images-idx3-ubyte
|
||||
└── xnist-labels-idx2-int
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@incollection{qmnist-2019,
|
||||
title = "Cold Case: The Lost MNIST Digits",
|
||||
author = "Chhavi Yadav and L\'{e}on Bottou",\
|
||||
booktitle = {Advances in Neural Information Processing Systems 32},
|
||||
year = {2019},
|
||||
publisher = {Curran Associates, Inc.},
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,34 +0,0 @@
|
|||
mindspore.dataset.RandomDataset
|
||||
===============================
|
||||
|
||||
.. py:class:: mindspore.dataset.RandomDataset(total_rows=None, schema=None, columns_list=None, num_samples=None, num_parallel_workers=None, cache=None, shuffle=None, num_shards=None, shard_id=None)
|
||||
|
||||
生成随机数据的源数据集。
|
||||
|
||||
参数:
|
||||
- **total_rows** (int, 可选) - 随机生成样本数据的数量。默认值:None,生成随机数量的样本。
|
||||
- **schema** (Union[str, Schema], 可选) - 读取模式策略,用于指定读取数据列的数据类型、数据维度等信息。
|
||||
支持传入JSON文件路径或 mindspore.dataset.Schema 构造的对象。默认值:None,不指定。
|
||||
- **columns_list** (list[str], 可选) - 指定生成数据集的列名,默认值:None,生成的数据列将以"c0","c1","c2" ... "cn"的规则命名。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取所有样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,123 +0,0 @@
|
|||
mindspore.dataset.SBDataset
|
||||
===========================
|
||||
|
||||
.. py:class:: mindspore.dataset.SBDataset(dataset_dir, task='Boundaries', usage='all', num_samples=None, num_parallel_workers=1, shuffle=None, decode=None, sampler=None, num_shards=None, shard_id=None)
|
||||
|
||||
读取和解析Semantic Boundaries数据集的源文件构建数据集。
|
||||
|
||||
根据给定的 `task` 配置,生成数据集具有不同的输出列:
|
||||
|
||||
- `task` = 'Boundaries',有两个输出列: `image` 列的数据类型为uint8。 `label` 列包含1个的数据类型为uint8的图像。
|
||||
- `task` = 'Segmentation',有两个输出列: `image` 列的数据类型为uint8。 `label` 列包含20个的数据类型为uint8的图像。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录的路径。
|
||||
- **task** (str, 可选) - 指定读取SB数据集的任务类型,支持'Boundaries'和'Segmentation'。默认值:'Boundaries'。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train'、'val'、'train_noval'和'all'。默认值:'train'。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,所有图像样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **decode** (bool, 可选) - 是否对读取的图片进行解码操作,默认值:False,不解码。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `dataset_dir` 不存在。
|
||||
- **ValueError** - `task` 不是['Boundaries', 'Segmentation']中的任何一个。
|
||||
- **ValueError** - `usage` 不是['train', 'val', 'train_noval', 'all']中的任何一个。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于Semantic Boundaries数据集:**
|
||||
|
||||
Semantic Boundaries(语义边界)数据集由11355张彩色图像组成。
|
||||
train.txt中有8498个图像,val.txt中有2857个图像,train_noval.txt中有5623个图像。
|
||||
目录cls中包含类别的分割和边界标注,目录inst中包含实例级的分割和边界标注。
|
||||
|
||||
可以将数据集文件解压缩为以下结构,并通过MindSpore的API读取:
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── benchmark_RELEASE
|
||||
├── dataset
|
||||
├── img
|
||||
│ ├── 2008_000002.jpg
|
||||
│ ├── 2008_000003.jpg
|
||||
│ ├── ...
|
||||
├── cls
|
||||
│ ├── 2008_000002.mat
|
||||
│ ├── 2008_000003.mat
|
||||
│ ├── ...
|
||||
├── inst
|
||||
│ ├── 2008_000002.mat
|
||||
│ ├── 2008_000003.mat
|
||||
│ ├── ...
|
||||
├── train.txt
|
||||
└── val.txt
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@InProceedings{BharathICCV2011,
|
||||
author = "Bharath Hariharan and Pablo Arbelaez and Lubomir Bourdev and
|
||||
Subhransu Maji and Jitendra Malik",
|
||||
title = "Semantic Contours from Inverse Detectors",
|
||||
booktitle = "International Conference on Computer Vision (ICCV)",
|
||||
year = "2011",
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,100 +0,0 @@
|
|||
mindspore.dataset.SBUDataset
|
||||
============================
|
||||
|
||||
.. py:class:: mindspore.dataset.SBUDataset(dataset_dir, num_samples=None, num_parallel_workers=None, shuffle=None, decode=False, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析SBU数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列:`[image, caption]`。`image` 列的数据类型为uint8,`caption` 列的数据类型为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录的路径。
|
||||
- **decode** (bool, 可选) - 是否对读取的图片进行解码操作,默认值:False,不解码。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,所有图像样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于SBU数据集:**
|
||||
|
||||
SBU数据集是一个带字幕的大型照片集,它包含一百万张带有视觉相关标注的图像。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└─ dataset_dir
|
||||
├── SBU_captioned_photo_dataset_captions.txt
|
||||
├── SBU_captioned_photo_dataset_urls.txt
|
||||
└── sbu_images
|
||||
├── m_3326_3596303505_3ce4c20529.jpg
|
||||
├── ......
|
||||
└── m_2522_4182181099_c3c23ab1cc.jpg
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@inproceedings{Ordonez:2011:im2text,
|
||||
Author = {Vicente Ordonez and Girish Kulkarni and Tamara L. Berg},
|
||||
Title = {Im2Text: Describing Images Using 1 Million Captioned Photographs},
|
||||
Booktitle = {Neural Information Processing Systems ({NIPS})},
|
||||
Year = {2011},
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,114 +0,0 @@
|
|||
mindspore.dataset.STL10Dataset
|
||||
==============================
|
||||
|
||||
.. py:class:: mindspore.dataset.STL10Dataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析STL10数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列: `[image, label]` 。 `image` 列的数据类型是uint8。`label` 列的数据类型是uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train'、'test'、'unlabeled'、'train+unlabeled'或'all'。
|
||||
取值为'train'时将会读取5,000个样本,取值为'test'时将会读取8,000个样本,取值为'unlabeled'时将会读取100,000个样本,取值为'train+unlabeled'时将会读取10,5000个样本,
|
||||
取值为'all'时将会读取全部类型的样本。默认值:None,读取全部样本图片。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `usage` 参数无效。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于STL10数据集:**
|
||||
|
||||
STL10数据集由10类组成:飞机、鸟、汽车、猫、鹿、狗、马、猴子、船、卡车。
|
||||
数据集样本均为96x96的彩色图像。
|
||||
每个类别分别有500张训练图像和800张测试图像,以及100000张没有标签的图像。
|
||||
标签索引从0开始标记,没有标签的的图像以-1作为标记。
|
||||
|
||||
以下是原始STL10数据集结构。
|
||||
可以将数据集文件解压缩到此目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── stl10_dataset_dir
|
||||
├── train_X.bin
|
||||
├── train_y.bin
|
||||
├── test_X.bin
|
||||
├── test_y.bin
|
||||
└── unlabeled_X.bin
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@techreport{Coates10,
|
||||
author = {Adam Coates},
|
||||
title = {Learning multiple layers of features from tiny images},
|
||||
year = {20010},
|
||||
howpublished = {https://cs.stanford.edu/~acoates/stl10/},
|
||||
description = {The STL-10 dataset consists of 96x96 RGB images in 10 classes,
|
||||
with 500 training images and 800 testing images per class.
|
||||
There are 5000 training images and 8000 test images.
|
||||
It also has 100000 unlabeled images for unsupervised learning.
|
||||
These examples are extracted from a similar but broader distribution of images.
|
||||
}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,103 +0,0 @@
|
|||
mindspore.dataset.SVHNDataset
|
||||
=============================
|
||||
|
||||
.. py:class:: mindspore.dataset.SVHNDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=1, shuffle=None, sampler=None, num_shards=None, shard_id=None)
|
||||
|
||||
读取和解析SVHN数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列: `[image, label]` 。 `image` 列的数据类型是uint8, `label` 列的数据类型是uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train'、'test'、'extra'或'all'。默认值:None,读取全部样本图片。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数,可以小于数据集总数。默认值:None,读取全部样本图片。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `usage` 参数无效。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于SVHN数据集:**
|
||||
|
||||
SVHN数据集是从谷歌街景图像中的门牌号码中获得的,由10位数字组成。
|
||||
|
||||
以下是原始SVHN数据集结构,可以将数据集文件解压缩到此目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── svhn_dataset_dir
|
||||
├── train_32x32.mat
|
||||
├── test_32x32.mat
|
||||
└── extra_32x32.mat
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{
|
||||
title={Reading Digits in Natural Images with Unsupervised Feature Learning},
|
||||
author={Yuval Netzer, Tao Wang, Adam Coates, Alessandro Bissacco, Bo Wu, Andrew Y. Ng},
|
||||
conference={NIPS Workshop on Deep Learning and Unsupervised Feature Learning 2011.},
|
||||
year={2011},
|
||||
publisher={NIPS}
|
||||
url={http://ufldl.stanford.edu/housenumbers}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,96 +0,0 @@
|
|||
mindspore.dataset.SemeionDataset
|
||||
================================
|
||||
|
||||
.. py:class:: mindspore.dataset.SemeionDataset(dataset_dir, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析Semeion数据集的源文件构建数据集。
|
||||
|
||||
生成的数据集有两列:`[image, label]`。`image` 列的数据类型为uint8,`label` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录的路径。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,所有图像样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于SEMEION数据集:**
|
||||
|
||||
该数据集由意大利布雷西亚Tactile Srl创建(http://www.tattil.it),并于1994年捐赠给意大利罗马Semeion通信科学研究中心(http://www.semeion.it),用于机器学习研究。
|
||||
此数据集由1593条样本记录(行)和256个属性(列)组成。每条记录代表一个手写数字,最初扫描的分辨率为256灰度。
|
||||
数据集拉伸了每个原始扫描图像的每个像素,然后在0和1之间缩放(将值低于灰度值127的每个像素(包括127)设置为0,并将灰度值超过127的每个像素设置为1)。
|
||||
最后,每个二进制图像再次缩放为一个16x16的方形图像。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── semeion_dataset_dir
|
||||
└──semeion.data
|
||||
└──semeion.names
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{
|
||||
title={The Theory of Independent Judges, in Substance Use & Misuse 33(2)1998, pp 439-461},
|
||||
author={M Buscema, MetaNet},
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,79 +0,0 @@
|
|||
mindspore.dataset.SogouNewsDataset
|
||||
==================================
|
||||
|
||||
.. py:class:: mindspore.dataset.SogouNewsDataset(dataset_dir, usage=None, num_samples=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, num_parallel_workers=None, cache=None)
|
||||
|
||||
读取和解析SogouNew数据集的源数据集。
|
||||
|
||||
生成的数据集有三列 `[index, title, content]` ,三列的数据类型均为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test'或'all'。默认值:None,读取全部样本。
|
||||
取值为'train'时将会读取45万个训练样本,取值为'test'时将会读取6万个测试样本,取值为'all'时将会读取全部51万个样本。默认值:None,读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 参数所指向的文件目录不存在或缺少数据集文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
|
||||
**关于SogouNew数据集:**
|
||||
|
||||
SogouNews 数据集包括3列,分别对应类别索引(1到5)、标题和内容。
|
||||
标题和内容使用双引号(")进行转义,任何内部双引号都使用2个双引号("")进行转义。
|
||||
新行使用反斜杠进行转义,后跟“n”字符,即"\n"。
|
||||
|
||||
以下是原始SogouNew数据集结构,可以将数据集文件解压缩到此目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── sogou_news_dir
|
||||
├── classes.txt
|
||||
├── readme.txt
|
||||
├── test.csv
|
||||
└── train.csv
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@misc{zhang2015characterlevel,
|
||||
title={Character-level Convolutional Networks for Text Classification},
|
||||
author={Xiang Zhang and Junbo Zhao and Yann LeCun},
|
||||
year={2015},
|
||||
eprint={1509.01626},
|
||||
archivePrefix={arXiv},
|
||||
primaryClass={cs.LG}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,108 +0,0 @@
|
|||
mindspore.dataset.SpeechCommandsDataset
|
||||
=======================================
|
||||
|
||||
.. py:class:: mindspore.dataset.SpeechCommandsDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析SpeechCommands数据集的源数据集。
|
||||
|
||||
生成的数据集有五列 `[waveform, sample_rate, label, speaker_id, utterance_number]` 。
|
||||
列 `waveform` 的数据类型为float32,列 `sample_rate` 的数据类型为int32,列 `label` 的数据类型为string,列 `speaker_id` 的数据类型为string,列 `utterance_number` 的数据类型为int32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test','valid'或'all'。默认值:None,读取全部样本。
|
||||
取值为'train'时将会读取84,843个训练样本,取值为'test'时将会读取11,005个测试样本,取值为'valid'时将会读取9,981个测试样本,取值为'all'时将会读取全部105,829个样本。默认值:None,读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取全部样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于SpeechCommands数据集:**
|
||||
|
||||
SpeechCommands(语音命令)数据是用于有限词汇语音识别的数据集,包含105,829个'.wav'格式的音频样本。
|
||||
|
||||
以下是原始SpeechCommands的数据集结构,可以将数据集文件解压缩成此目录结构,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── speech_commands_dataset_dir
|
||||
├── cat
|
||||
├── b433eff_nohash_0.wav
|
||||
├── 5a33edf_nohash_1.wav
|
||||
└──....
|
||||
├── dog
|
||||
├── b433w2w_nohash_0.wav
|
||||
└──....
|
||||
├── four
|
||||
└── ....
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{2018Speech,
|
||||
title={Speech Commands: A Dataset for Limited-Vocabulary Speech Recognition},
|
||||
author={Warden, P.},
|
||||
year={2018}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -26,7 +26,7 @@ mindspore.dataset.TFRecordDataset
|
|||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后,`num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **shard_equal_rows** (bool, 可选) - 分布式训练时,为所有分片获取等量的数据行数。默认值:False。如果 `shard_equal_rows` 为False,则可能会使得每个分片的数据条目不相等,从而导致分布式训练失败。因此当每个TFRecord文件的数据数量不相等时,建议将此参数设置为True。注意,只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **ValueError** - `dataset_files` 参数所指向的文件无效或不存在。
|
||||
|
|
|
@ -1,170 +0,0 @@
|
|||
mindspore.dataset.TedliumDataset
|
||||
================================
|
||||
|
||||
.. py:class:: mindspore.dataset.TedliumDataset(dataset_dir, release, usage=None, extensions=None, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析Tedlium数据集的源数据集,生成的数据集的列取决于源SPH文件和相应的STM文件。
|
||||
|
||||
生成的数据集有六列 `[waveform, sample_rate, transcript, talk_id, speaker_id, identifier]` 。
|
||||
列 `waveform` 的数据类型为float32,列 `sample_rate` 的数据类型为int32,列 `transcript` 的数据类型为string,列 `talk_id` 的数据类型为string,列 `speaker_id` 的数据类型为string,列 `identifier` 的数据类型为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **release** (str) - 指定数据集的发布版本,可以取值为'release1'、'release2'或'release3'。
|
||||
- **usage** (str, 可选) - 指定数据集的子集。
|
||||
对于 `release` 为'release1'或'release2', `usage` 可以是'train'、'test'、'dev'或'all'。
|
||||
对于 `release` 为'release3', `usage` 只能是'all'。默认值:None,读取全部样本。
|
||||
- **extensions** (str, 可选) - 指定SPH文件的扩展名。默认值:'.sph'。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取全部样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于TEDLIUM数据集:**
|
||||
|
||||
TEDLIUM_release1数据集:TED-LUM语料库是英语TED演讲,有转录,采样频率为16kHz。包含了大约118小时的演讲。
|
||||
|
||||
TEDLIUM_release2数据集:这是TED-LIUM语料库版本2,根据知识共享BY-NC-ND 3.0授权。所有会谈和文本均为TED会议有限责任公司的财产。TED-LIUM语料库是由音频谈话和他们的转录在TED网站上提供的。我们准备并过滤了这些数据,以便训练声学模型参加2011年口语翻译国际研讨会(LIUM英语/法语SLT系统在SLT任务中排名第一)。
|
||||
|
||||
TEDLIUM_release-3数据集:这是TED-LIUM语料库版本3,根据知识共享BY-NC-ND 3.0授权。所有会谈和文本均为TED会议有限责任公司的财产。这个新的TED-LIUM版本是通过Ubiqus公司和LIUM(法国勒芒大学)的合作发布的。
|
||||
|
||||
可以将数据集文件解压缩到以下目录结构中,并由MindSpore的API读取。
|
||||
|
||||
TEDLIUM release1与TEDLIUM release2的结构相同,只是数据不同。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└──TEDLIUM_release1
|
||||
└── dev
|
||||
├── sph
|
||||
├── AlGore_2009.sph
|
||||
├── BarrySchwartz_2005G.sph
|
||||
├── stm
|
||||
├── AlGore_2009.stm
|
||||
├── BarrySchwartz_2005G.stm
|
||||
└── test
|
||||
├── sph
|
||||
├── AimeeMullins_2009P.sph
|
||||
├── BillGates_2010.sph
|
||||
├── stm
|
||||
├── AimeeMullins_2009P.stm
|
||||
├── BillGates_2010.stm
|
||||
└── train
|
||||
├── sph
|
||||
├── AaronHuey_2010X.sph
|
||||
├── AdamGrosser_2007.sph
|
||||
├── stm
|
||||
├── AaronHuey_2010X.stm
|
||||
├── AdamGrosser_2007.stm
|
||||
└── readme
|
||||
└── TEDLIUM.150k.dic
|
||||
|
||||
TEDLIUM release3目录结构稍有不同。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└──TEDLIUM_release-3
|
||||
└── data
|
||||
├── ctl
|
||||
├── sph
|
||||
├── 911Mothers_2010W.sph
|
||||
├── AalaElKhani.sph
|
||||
├── stm
|
||||
├── 911Mothers_2010W.stm
|
||||
├── AalaElKhani.stm
|
||||
└── doc
|
||||
└── legacy
|
||||
└── LM
|
||||
└── speaker-adaptation
|
||||
└── readme
|
||||
└── TEDLIUM.150k.dic
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{
|
||||
title={TED-LIUM: an automatic speech recognition dedicated corpus},
|
||||
author={A. Rousseau, P. Deléglise, Y. Estève},
|
||||
journal={Proceedings of the Eighth International Conference on Language Resources and Evaluation (LREC'12)},
|
||||
year={May 2012},
|
||||
biburl={https://www.openslr.org/7/}
|
||||
}
|
||||
|
||||
@article{
|
||||
title={Enhancing the TED-LIUM Corpus with Selected Data for Language Modeling and More TED Talks},
|
||||
author={A. Rousseau, P. Deléglise, and Y. Estève},
|
||||
journal={Proceedings of the Eighth International Conference on Language Resources and Evaluation (LREC'12)},
|
||||
year={May 2014},
|
||||
biburl={https://www.openslr.org/19/}
|
||||
}
|
||||
|
||||
@article{
|
||||
title={TED-LIUM 3: twice as much data and corpus repartition for experiments on speaker adaptation},
|
||||
author={François Hernandez, Vincent Nguyen, Sahar Ghannay, Natalia Tomashenko, and Yannick Estève},
|
||||
journal={the 20th International Conference on Speech and Computer (SPECOM 2018)},
|
||||
year={September 2018},
|
||||
biburl={https://www.openslr.org/51/}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,46 +1,46 @@
|
|||
mindspore.dataset.TextFileDataset
|
||||
==================================
|
||||
|
||||
.. py:class:: mindspore.dataset.TextFileDataset(dataset_files, num_samples=None, num_parallel_workers=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析文本文件构建数据集。生成的数据集有一个数据列:`[text]` ,类型为string。
|
||||
|
||||
参数:
|
||||
- **dataset_files** (Union[str, list[str]]) - 数据集文件路径,支持单文件路径字符串、多文件路径字符串列表或可被glob库模式匹配的字符串,文件列表将在内部进行字典排序。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取所有样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **ValueError** - `dataset_files` 参数所指向的文件无效或不存在。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
mindspore.dataset.TextFileDataset
|
||||
==================================
|
||||
|
||||
.. py:class:: mindspore.dataset.TextFileDataset(dataset_files, num_samples=None, num_parallel_workers=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析文本文件构建数据集。生成的数据集有一个数据列:`[text]` ,类型为string。
|
||||
|
||||
参数:
|
||||
- **dataset_files** (Union[str, list[str]]) - 数据集文件路径,支持单文件路径字符串、多文件路径字符串列表或可被glob库模式匹配的字符串,文件列表将在内部进行字典排序。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取所有样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **ValueError** - `dataset_files` 参数所指向的文件无效或不存在。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,49 +0,0 @@
|
|||
mindspore.dataset.UDPOSDataset
|
||||
==============================
|
||||
|
||||
.. py:class:: mindspore.dataset.UDPOSDataset(dataset_dir, usage=None, num_samples=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, num_parallel_workers=None, cache=None)
|
||||
|
||||
读取和解析UDPOS数据集的源数据集。
|
||||
|
||||
生成的数据集有三列 `[word, universal, stanford]` ,三列的数据类型均为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train'、'test'、'valid'或'all'。
|
||||
取值为'train'时将会读取12,543个样本,取值为'test'时将会读取2,077个测试样本,取值为'test'时将会读取9,981个样本,取值为'valid'时将会读取2,002个样本,取值为'all'时将会读取全部16,622个样本。默认值:None,读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取全部样本。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 参数所指向的文件目录不存在或缺少数据集文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,75 +0,0 @@
|
|||
mindspore.dataset.USPSDataset
|
||||
=============================
|
||||
|
||||
.. py:class:: mindspore.dataset.USPSDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析UDPOS数据集的源数据集。
|
||||
|
||||
生成的数据集有两列: `[image, label]`。 `image` 列的数据类型为uint8。 `label` 列的数据类型为uint32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train'、'test'、或'all'。
|
||||
取值为'train'时将会读取7,291个样本,取值为'test'时将会读取2,077个测试样本,取值为'test'时将会读取2,007个样本,取值为'all'时将会读取全部9,298个样本。默认值:None,读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `usage` 参数无效。
|
||||
- **ValueError** - `shard_id` 参数错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
**关于USPS数据集:**
|
||||
|
||||
USPS是美国邮政服务公司从信封中自动扫描的数字数据集,包含总共9,298个16×16像素灰度样本。
|
||||
|
||||
以下是原始的USPS数据集结构,可以将数据集文件下载并解压缩到此目录结构中,并通过MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── usps_dataset_dir
|
||||
├── usps
|
||||
├── usps.t
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{hull1994database,
|
||||
title={A database for handwritten text recognition research},
|
||||
author={Hull, Jonathan J.},
|
||||
journal={IEEE Transactions on pattern analysis and machine intelligence},
|
||||
volume={16},
|
||||
number={5},
|
||||
pages={550--554},
|
||||
year={1994},
|
||||
publisher={IEEE}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -26,7 +26,7 @@ mindspore.dataset.VOCDataset
|
|||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/r1.10/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
- **extra_metadata** (bool, 可选) - 用于指定是否额外输出一个数据列用于表示图片元信息。如果为True,则将额外输出一个名为 `[_meta-filename, dtype=string]` 的数据列,默认值:False。
|
||||
- **decrypt** (callable, 可选) - 图像解密函数,接受加密的图片路径并返回bytes类型的解密数据。默认值:None,不进行解密。
|
||||
|
||||
|
|
|
@ -1,129 +0,0 @@
|
|||
mindspore.dataset.WIDERFaceDataset
|
||||
==================================
|
||||
|
||||
.. py:class:: mindspore.dataset.WIDERFaceDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=None, decode=False, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析WIDERFace数据集的源数据集。
|
||||
|
||||
当 `usage` 为"train"、"valid"或"all"时,生成的数据集有八列 `["image", "bbox", "blur", "expression", "illumination", "occlusion", "pose", "invalid"]` ,其中 `image` 列的数据类型为uint8,其他列均为uint32。
|
||||
当 `usage` 为"test"时,生成的数据集只有一列 `["image"]` ,数据类型为uint8。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train'、'test'、'valid'或'all'。
|
||||
取值为'train'时将会读取12,880个样本,取值为'test'时将会读取2,077个测试样本,取值为'test'时将会读取16,097个样本,取值为'valid'时将会读取3,226个样本,取值为'all'时将会读取全部类别样本。默认值:None,读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取全部样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **decode** (bool, 可选) - 是否对读取的图片进行解码操作,默认值:False,不解码。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 不包含任何数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
- **ValueError** - `usage` 不在['train', 'test', 'valid', 'all']中。
|
||||
- **ValueError** - `annotation_file` 不存在。
|
||||
- **ValueError** - `dataset_dir` 不存在。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于WIDERFace数据集:**
|
||||
|
||||
WIDER FACE数据集是人脸检测的一个benchmark数据集,包含393,703个标注人脸,其中,158,989个标注人脸位于训练集,
|
||||
39,496个位于验证集。每一个样本集都包含3个级别的检测难度:Easy,Medium,Hard。这些人脸在尺度,姿态,光照、表情、遮挡方面都有很大的变化范围。
|
||||
|
||||
以下是原始的WIDERFace数据集结构,可以将数据集文件解压缩到此目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── wider_face_dir
|
||||
├── WIDER_test
|
||||
│ └── images
|
||||
│ ├── 0--Parade
|
||||
│ │ ├── 0_Parade_marchingband_1_9.jpg
|
||||
│ │ ├── ...
|
||||
│ ├──1--Handshaking
|
||||
│ ├──...
|
||||
├── WIDER_train
|
||||
│ └── images
|
||||
│ ├── 0--Parade
|
||||
│ │ ├── 0_Parade_marchingband_1_11.jpg
|
||||
│ │ ├── ...
|
||||
│ ├──1--Handshaking
|
||||
│ ├──...
|
||||
├── WIDER_val
|
||||
│ └── images
|
||||
│ ├── 0--Parade
|
||||
│ │ ├── 0_Parade_marchingband_1_102.jpg
|
||||
│ │ ├── ...
|
||||
│ ├──1--Handshaking
|
||||
│ ├──...
|
||||
└── wider_face_split
|
||||
├── wider_face_test_filelist.txt
|
||||
├── wider_face_train_bbx_gt.txt
|
||||
└── wider_face_val_bbx_gt.txt
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@inproceedings{2016WIDER,
|
||||
title={WIDERFACE: A Detection Benchmark},
|
||||
author={Yang, S. and Luo, P. and Loy, C. C. and Tang, X.},
|
||||
booktitle={IEEE},
|
||||
pages={5525-5533},
|
||||
year={2016},
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -3,18 +3,18 @@ mindspore.dataset.WaitedDSCallback
|
|||
|
||||
.. py:class:: mindspore.dataset.WaitedDSCallback(step_size=1)
|
||||
|
||||
阻塞式数据处理回调类的抽象基类,用于与训练回调类 `mindspore.Callback <https://www.mindspore.cn/docs/zh-CN/master/api_python/mindspore/mindspore.Callback.html#mindspore.Callback>`_ 的同步。
|
||||
阻塞式数据处理回调类的抽象基类,用于与训练回调类 `mindspore.Callback <https://www.mindspore.cn/docs/zh-CN/r1.10/api_python/mindspore/mindspore.Callback.html#mindspore.Callback>`_ 的同步。
|
||||
|
||||
可用于在step或epoch开始前执行自定义的回调方法,例如在自动数据增强中根据上一个epoch的loss值来更新增强算子参数配置。
|
||||
|
||||
用户可通过 `train_run_context` 获取网络训练相关信息,如 `network` 、 `train_network` 、 `epoch_num` 、 `batch_num` 、 `loss_fn` 、 `optimizer` 、 `parallel_mode` 、 `device_number` 、 `list_callback` 、 `cur_epoch_num` 、 `cur_step_num` 、 `dataset_sink_mode` 、 `net_outputs` 等,详见 `mindspore.Callback <https://www.mindspore.cn/docs/zh-CN/master/api_python/mindspore/mindspore.Callback.html#mindspore.Callback>`_ 。
|
||||
用户可通过 `train_run_context` 获取网络训练相关信息,如 `network` 、 `train_network` 、 `epoch_num` 、 `batch_num` 、 `loss_fn` 、 `optimizer` 、 `parallel_mode` 、 `device_number` 、 `list_callback` 、 `cur_epoch_num` 、 `cur_step_num` 、 `dataset_sink_mode` 、 `net_outputs` 等,详见 `mindspore.Callback <https://www.mindspore.cn/docs/zh-CN/r1.10/api_python/mindspore/mindspore.Callback.html#mindspore.Callback>`_ 。
|
||||
|
||||
用户可通过 `ds_run_context` 获取数据处理管道相关信息,包括 `cur_epoch_num` (当前epoch数)、 `cur_step_num_in_epoch` (当前epoch的step数)、 `cur_step_num` (当前step数)。
|
||||
|
||||
.. note:: 注意,第2个step或epoch开始时才会触发该调用。
|
||||
|
||||
参数:
|
||||
- **step_size** (int, optional) - 每个step包含的数据行数。通常step_size与batch_size一致,默认值:1。
|
||||
- **step_size** (int, 可选) - 每个step包含的数据行数。通常step_size与batch_size一致,默认值:1。
|
||||
|
||||
.. py:method:: sync_epoch_begin(train_run_context, ds_run_context)
|
||||
|
||||
|
|
|
@ -1,70 +0,0 @@
|
|||
mindspore.dataset.WikiTextDataset
|
||||
=================================
|
||||
|
||||
.. py:class:: mindspore.dataset.WikiTextDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析WikiText2和WikiText103数据集的源数据集。
|
||||
|
||||
生成的数据集有一列 `[text]` ,数据类型为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train', 'test', 'valid'或'all'。默认值:None,读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取全部样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
**关于WikiText数据集:**
|
||||
|
||||
WikiText数据集是一个包含1亿字的英语词典。
|
||||
这些样本术语来自维基百科的高级和基础文章,包括Wikitext2和Wikitext103的版本。
|
||||
对于WikiText2,分别在wiki.train.tokens中有36718个样本,在wiki.test.tokens中有4358个样本,在wiki.valid.tokens中有3760个样本。
|
||||
对于WikiText103,分别在wiki.train.tokens中有1801350个样本,wiki.test.tokens中的4358个样本,Wiki.valid.tokens中的3760个样本。
|
||||
|
||||
以下是原始的WikiText数据集结构,可以将数据集文件解压缩到此目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── WikiText2/WikiText103
|
||||
├── wiki.train.tokens
|
||||
├── wiki.test.tokens
|
||||
├── wiki.valid.tokens
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{merity2016pointer,
|
||||
title={Pointer sentinel mixture models},
|
||||
author={Merity, Stephen and Xiong, Caiming and Bradbury, James and Socher, Richard},
|
||||
journal={arXiv preprint arXiv:1609.07843},
|
||||
year={2016}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,78 +0,0 @@
|
|||
mindspore.dataset.YahooAnswersDataset
|
||||
=====================================
|
||||
|
||||
.. py:class:: mindspore.dataset.YahooAnswersDataset(dataset_dir, usage=None, num_samples=None, num_parallel_workers=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析YahooAnswers数据集的源数据集。
|
||||
|
||||
生成的数据集有四列 `[class, title, content, answer]` ,数据类型均为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train', 'test'或'all'。
|
||||
取值为'train'时将会读取1,400,000个训练样本,取值为'test'时将会读取60,000个测试样本,取值为'all'时将会读取全部1,460,000个样本。默认值:None,读取全部样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取全部样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 参数所指向的文件目录不存在或缺少数据集文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
**关于YahooAnswers数据集:**
|
||||
|
||||
YahooAnswers数据集包含10个类的63万个文本样本。
|
||||
train.csv中有56万个样本,test.csv中有7万个样本。
|
||||
这10个不同的类代表社会与文化、科学与数学、健康、教育与参考、计算机与互联网、体育、商业与金融、娱乐与音乐、家庭与关系、政治与政府。
|
||||
|
||||
以下是原始的YahooAnswers数据集结构,可以将数据集文件解压缩到此目录结构中,并由Mindspore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── yahoo_answers_dataset_dir
|
||||
├── train.csv
|
||||
├── test.csv
|
||||
├── classes.txt
|
||||
└── readme.txt
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{YahooAnswers,
|
||||
title = {Yahoo! Answers Topic Classification Dataset},
|
||||
author = {Xiang Zhang},
|
||||
year = {2015},
|
||||
howpublished = {}
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,107 +0,0 @@
|
|||
mindspore.dataset.YelpReviewDataset
|
||||
===================================
|
||||
|
||||
.. py:class:: mindspore.dataset.YelpReviewDataset(dataset_dir, usage=None, num_samples=None, shuffle=Shuffle.GLOBAL, num_shards=None, shard_id=None, num_parallel_workers=None, cache=None)
|
||||
|
||||
读取和解析Yelp Review Full和Yelp Review Polarity数据集的源数据集。
|
||||
|
||||
生成的数据集有两列 `[label, text]` ,两列的数据类型均为string。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **usage** (str, 可选) - 指定数据集的子集,可取值为'train','test'或'all'。默认值:None,读取全部样本。
|
||||
对于Polarity数据集,'train'将读取560,000个训练样本,'test'将读取38,000个测试样本,'all'将读取所有598,000个样本。
|
||||
对于Full数据集,'train'将读取650,000个训练样本,'test'将读取50,000个测试样本,'all'将读取所有700,000个样本。默认值:None,读取所有样本。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取全部样本。
|
||||
- **shuffle** (Union[bool, Shuffle], 可选) - 每个epoch中数据混洗的模式,支持传入bool类型与枚举类型进行指定,默认值:mindspore.dataset.Shuffle.GLOBAL。
|
||||
如果 `shuffle` 为False,则不混洗,如果 `shuffle` 为True,等同于将 `shuffle` 设置为mindspore.dataset.Shuffle.GLOBAL。
|
||||
通过传入枚举变量设置数据混洗的模式:
|
||||
|
||||
- **Shuffle.GLOBAL**:混洗文件和样本。
|
||||
- **Shuffle.FILES**:仅混洗文件。
|
||||
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 参数所指向的文件目录不存在或缺少数据集文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
|
||||
**关于YelpReview数据集:**
|
||||
|
||||
Yelp Review Full数据集包括来自Yelp的评论数据,这些数据时从2015年的Yelp数据集挑战赛数据中提取的,主要用于文本分类。
|
||||
|
||||
Yelp Review Polarity数据集在Full数据集的基础上,对产品评分进行了分级,评论分数1和2视为负面评论,4和5视为正面评论。
|
||||
|
||||
Yelp Reviews Polarity和Yelp Reviews Full datasets具有相同的目录结构。
|
||||
可以将数据集文件解压缩到以下结构,并通过MindSpore的API读取:
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── yelp_review_dir
|
||||
├── train.csv
|
||||
├── test.csv
|
||||
└── readme.txt
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{zhangCharacterlevelConvolutionalNetworks2015,
|
||||
archivePrefix = {arXiv},
|
||||
eprinttype = {arxiv},
|
||||
eprint = {1509.01626},
|
||||
primaryClass = {cs},
|
||||
title = {Character-Level {{Convolutional Networks}} for {{Text Classification}}},
|
||||
abstract = {This article offers an empirical exploration on the use of character-level convolutional networks
|
||||
(ConvNets) for text classification. We constructed several large-scale datasets to show that
|
||||
character-level convolutional networks could achieve state-of-the-art or competitive results.
|
||||
Comparisons are offered against traditional models such as bag of words, n-grams and their TFIDF
|
||||
variants, and deep learning models such as word-based ConvNets and recurrent neural networks.},
|
||||
journal = {arXiv:1509.01626 [cs]},
|
||||
author = {Zhang, Xiang and Zhao, Junbo and LeCun, Yann},
|
||||
month = sep,
|
||||
year = {2015},
|
||||
}
|
||||
|
||||
.. code-block::
|
||||
|
||||
@article{zhangCharacterlevelConvolutionalNetworks2015,
|
||||
archivePrefix = {arXiv},
|
||||
eprinttype = {arxiv},
|
||||
eprint = {1509.01626},
|
||||
primaryClass = {cs},
|
||||
title = {Character-Level {{Convolutional Networks}} for {{Text Classification}}},
|
||||
abstract = {This article offers an empirical exploration on the use of character-level convolutional networks
|
||||
(ConvNets) for text classification. We constructed several large-scale datasets to show that
|
||||
character-level convolutional networks could achieve state-of-the-art or competitive results.
|
||||
Comparisons are offered against traditional models such as bag of words, n-grams and their TFIDF
|
||||
variants, and deep learning models such as word-based ConvNets and recurrent neural networks.},
|
||||
journal = {arXiv:1509.01626 [cs]},
|
||||
author = {Zhang, Xiang and Zhao, Junbo and LeCun, Yann},
|
||||
month = sep,
|
||||
year = {2015},
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.c.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -1,100 +0,0 @@
|
|||
mindspore.dataset.YesNoDataset
|
||||
==============================
|
||||
|
||||
.. py:class:: mindspore.dataset.YesNoDataset(dataset_dir, num_samples=None, num_parallel_workers=None, shuffle=None, sampler=None, num_shards=None, shard_id=None, cache=None)
|
||||
|
||||
读取和解析YesNo数据集的源数据集。
|
||||
|
||||
生成的数据集有三列 `[waveform, sample_rate, labels]` 。
|
||||
列 `waveform` 的数据类型为float32,列 `sample_rate` 的数据类型为int32,列 `labels` 的数据类型为int32。
|
||||
|
||||
参数:
|
||||
- **dataset_dir** (str) - 包含数据集文件的根目录路径。
|
||||
- **num_samples** (int, 可选) - 指定从数据集中读取的样本数。默认值:None,读取全部样本。
|
||||
- **num_parallel_workers** (int, 可选) - 指定读取数据的工作线程数。默认值:None,使用mindspore.dataset.config中配置的线程数。
|
||||
- **shuffle** (bool, 可选) - 是否混洗数据集。默认值:None,下表中会展示不同参数配置的预期行为。
|
||||
- **sampler** (Sampler, 可选) - 指定从数据集中选取样本的采样器,默认值:None,下表中会展示不同配置的预期行为。
|
||||
- **num_shards** (int, 可选) - 指定分布式训练时将数据集进行划分的分片数,默认值:None。指定此参数后, `num_samples` 表示每个分片的最大样本数。
|
||||
- **shard_id** (int, 可选) - 指定分布式训练时使用的分片ID号,默认值:None。只有当指定了 `num_shards` 时才能指定此参数。
|
||||
- **cache** (DatasetCache, 可选) - 单节点数据缓存服务,用于加快数据集处理,详情请阅读 `单节点数据缓存 <https://www.mindspore.cn/tutorials/experts/zh-CN/master/dataset/cache.html>`_ 。默认值:None,不使用缓存。
|
||||
|
||||
异常:
|
||||
- **RuntimeError** - `dataset_dir` 路径下不包含任何数据文件。
|
||||
- **ValueError** - `num_parallel_workers` 参数超过系统最大线程数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `shuffle` 参数。
|
||||
- **RuntimeError** - 同时指定了 `sampler` 和 `num_shards` 参数或同时指定了 `sampler` 和 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `num_shards` 参数,但是未指定 `shard_id` 参数。
|
||||
- **RuntimeError** - 指定了 `shard_id` 参数,但是未指定 `num_shards` 参数。
|
||||
- **ValueError** - `shard_id` 参数值错误(小于0或者大于等于 `num_shards` )。
|
||||
|
||||
.. note:: 此数据集可以指定参数 `sampler` ,但参数 `sampler` 和参数 `shuffle` 的行为是互斥的。下表展示了几种合法的输入参数组合及预期的行为。
|
||||
|
||||
.. list-table:: 配置 `sampler` 和 `shuffle` 的不同组合得到的预期排序结果
|
||||
:widths: 25 25 50
|
||||
:header-rows: 1
|
||||
|
||||
* - 参数 `sampler`
|
||||
- 参数 `shuffle`
|
||||
- 预期数据顺序
|
||||
* - None
|
||||
- None
|
||||
- 随机排列
|
||||
* - None
|
||||
- True
|
||||
- 随机排列
|
||||
* - None
|
||||
- False
|
||||
- 顺序排列
|
||||
* - `sampler` 实例
|
||||
- None
|
||||
- 由 `sampler` 行为定义的顺序
|
||||
* - `sampler` 实例
|
||||
- True
|
||||
- 不允许
|
||||
* - `sampler` 实例
|
||||
- False
|
||||
- 不允许
|
||||
|
||||
**关于YesNo数据集:**
|
||||
|
||||
Yesno是一个音频数据集,由60个录音组成,由一个人用希伯来语说是或不是;每个录音都有8个字长。
|
||||
|
||||
以下是原始的YesNo数据集结构,可以将数据集文件解压缩到此目录结构中,并由MindSpore的API读取。
|
||||
|
||||
.. code-block::
|
||||
|
||||
.
|
||||
└── yes_no_dataset_dir
|
||||
├── 1_1_0_0_1_1_0_0.wav
|
||||
├── 1_0_0_0_1_1_0_0.wav
|
||||
├── 1_1_0_0_1_1_0_0.wav
|
||||
└──....
|
||||
|
||||
**引用:**
|
||||
|
||||
.. code-block::
|
||||
|
||||
@NetworkResource{Kaldi_audio_project,
|
||||
author = {anonymous},
|
||||
url = "http://wwww.openslr.org/1/"
|
||||
}
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.add_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.b.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.d.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.e.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.f.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.save.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.g.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.use_sampler.rst
|
||||
|
||||
.. include:: mindspore.dataset.Dataset.zip.rst
|
|
@ -5,9 +5,6 @@ mindspore.dataset.deserialize
|
|||
|
||||
数据处理管道反序列化,支持输入Python字典或使用 `mindspore.dataset.serialize()` 接口生成的JSON文件。
|
||||
|
||||
.. note::
|
||||
反序列化包含自定义Python函数的数据处理管道时,部分参数信息可能丢失;当 `input_dict` 和 `json_filepath` 同时不为None时,返回反序列化JSON文件的结果。
|
||||
|
||||
参数:
|
||||
- **input_dict** (dict) - 以Python字典存储的数据处理管道。默认值:None。
|
||||
- **json_filepath** (str) - 数据处理管道JSON文件的路径,该文件以通用JSON格式存储了数据处理管道信息,用户可通过 `mindspore.dataset.serialize()` 接口生成。默认值:None。
|
||||
|
@ -16,4 +13,4 @@ mindspore.dataset.deserialize
|
|||
当反序列化成功时,将返回Dataset对象;当无法被反序列化时,deserialize将会失败,且返回None。
|
||||
|
||||
异常:
|
||||
- **OSError** - `json_filepath` 不为None且JSON文件解析失败时。
|
||||
- **OSError** - 无法打开 `json_filepath` 指定的文件。
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
参数:
|
||||
- **dataset** (Dataset) - 数据处理管道对象。
|
||||
- **json_filepath** (str) - 生成序列化JSON文件的路径。
|
||||
- **json_filepath** (str) - 生成序列化JSON文件的路径,默认值:'',不指定JSON路径。
|
||||
|
||||
返回:
|
||||
Dict,包含序列化数据集图的字典。
|
||||
|
|
|
@ -7,4 +7,4 @@ mindspore.dataset.show
|
|||
|
||||
参数:
|
||||
- **dataset** (Dataset) - 数据处理管道对象。
|
||||
- **indentation** (int, optional) - 设置MindSpore的INFO级别日志文件打印时的缩进字符数。若为None,则不缩进。
|
||||
- **indentation** (int, 可选) - 设置MindSpore的INFO级别日志文件打印时的缩进字符数。若为None,则不缩进。
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
- **bboxes** (numpy.ndarray) - 边界框(包含类别置信度),shape为(N, 4)或(N, 5),格式为(N,X,Y,W,H)。
|
||||
- **labels** (numpy.ndarray) - 边界框的类别,shape为(N, 1)。
|
||||
- **segm** (numpy.ndarray) - 图像分割掩码,shape为(M, H, W),M表示类别总数,默认值:None,不绘制掩码。
|
||||
- **class_names** (list[str], dict) - 类别索引到类别名的映射表,默认值:None,仅显示类别索引。
|
||||
- **class_names** (list[str], tuple[str], dict) - 类别索引到类别名的映射表,默认值:None,仅显示类别索引。
|
||||
- **score_threshold** (float) - 绘制边界框的类别置信度阈值,默认值:0,绘制所有边界框。
|
||||
- **bbox_color** (tuple(int)) - 指定绘制边界框时线条的颜色,顺序为BGR,默认值:(0,255,0),表示绿色。
|
||||
- **text_color** (tuple(int)) - 指定类别文本的显示颜色,顺序为BGR,默认值:(203, 192, 255),表示粉色。
|
||||
|
@ -20,7 +20,7 @@
|
|||
- **show** (bool) - 是否显示图像,默认值:True。
|
||||
- **win_name** (str) - 指定窗口名称,默认值:"win"。
|
||||
- **wait_time** (int) - 指定cv2.waitKey的时延,单位为ms,即图像显示的自动切换间隔,默认值:2000,表示间隔为2000ms。
|
||||
- **out_file** (str, optional) - 输出图像的文件路径,用于在绘制后将结果存储到本地,默认值:None,不保存。
|
||||
- **out_file** (str, 可选) - 输出图像的文件路径,用于在绘制后将结果存储到本地,默认值:None,不保存。
|
||||
|
||||
返回:
|
||||
numpy.ndarray,带边界框和类别置信度的图像。
|
||||
|
|
|
@ -8,7 +8,7 @@ mindspore.dataset.audio.AmplitudeToDB
|
|||
.. note:: 待处理音频维度需为(..., freq, time)。
|
||||
|
||||
参数:
|
||||
- **stype** ( :class:`mindspore.dataset.audio.utils.ScaleType` , 可选) - 输入音频的原始标度,取值可为ScaleType.MAGNITUDE或ScaleType.POWER,默认值:ScaleType.POWER。
|
||||
- **stype** ( :class:`mindspore.dataset.audio.ScaleType` , 可选) - 输入音频的原始标度,取值可为ScaleType.MAGNITUDE或ScaleType.POWER,默认值:ScaleType.POWER。
|
||||
- **ref_value** (float, 可选) - 系数参考值,默认值:1.0,用于计算分贝系数 `db_multiplier` ,公式为
|
||||
:math:`db\_multiplier = Log10(max(ref\_value, amin))`。
|
||||
|
||||
|
@ -16,7 +16,7 @@ mindspore.dataset.audio.AmplitudeToDB
|
|||
- **top_db** (float, 可选) - 最小截止分贝值,取值为非负数,默认值:80.0。
|
||||
|
||||
异常:
|
||||
- **TypeError** - 当 `stype` 的类型不为 :class:`mindspore.dataset.audio.utils.ScaleType` 。
|
||||
- **TypeError** - 当 `stype` 的类型不为 :class:`mindspore.dataset.audio.ScaleType` 。
|
||||
- **TypeError** - 当 `ref_value` 的类型不为float。
|
||||
- **ValueError** - 当 `ref_value` 不为正数。
|
||||
- **TypeError** - 当 `amin` 的类型不为float。
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
mindspore.dataset.text.WordpieceTokenizer
|
||||
=========================================
|
||||
|
||||
.. py:class:: mindspore.dataset.text.WordpieceTokenizer(vocab, suffix_indicator='##', max_bytes_per_token=100,unknown_token='[UNK]', with_offsets=False)
|
||||
.. py:class:: mindspore.dataset.text.WordpieceTokenizer(vocab, suffix_indicator='##', max_bytes_per_token=100, unknown_token='[UNK]', with_offsets=False)
|
||||
|
||||
将输入的字符串切分为子词。
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ mindspore.dataset.vision.RgbToHsv
|
|||
将输入的RGB格式numpy.ndarray图像转换为HSV格式。
|
||||
|
||||
参数:
|
||||
- **is_hwc** (bool) - 若为True,表示输入图像的shape为(H, W, C)或(N, H, W, C);否则为(C, H, W)或(N, C, H, W)。默认值:False。
|
||||
- **is_hwc** (bool) - 若为True,表示输入图像的shape为(H, W, C)或(N, H, W, C);否则为(C, H, W)或(N, C, H, W)。默认值:False。
|
||||
|
||||
异常:
|
||||
- **TypeError** - 当 `is_hwc` 的类型不为bool。
|
||||
- **TypeError** - 当 `is_hwc` 的类型不为bool。
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
将CIFAR-100数据集转换为MindRecord格式数据集。
|
||||
|
||||
.. note::
|
||||
示例的详细信息,请参见 `转换CIFAR-10数据集 <https://www.mindspore.cn/tutorials/zh-CN/master/advanced/dataset/record.html#转换cifar-10数据集>`_。
|
||||
示例的详细信息,请参见 `转换CIFAR-10数据集 <https://www.mindspore.cn/tutorials/zh-CN/r1.10/advanced/dataset/record.html#转换cifar-10数据集>`_。
|
||||
|
||||
参数:
|
||||
- **source** (str) - 待转换的CIFAR-100数据集文件所在目录的路径。
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
将CIFAR-10数据集转换为MindRecord格式数据集。
|
||||
|
||||
.. note::
|
||||
示例的详细信息,请参见 `转换CIFAR-10数据集 <https://www.mindspore.cn/tutorials/zh-CN/master/advanced/dataset/record.html#转换cifar-10数据集>`_。
|
||||
示例的详细信息,请参见 `转换CIFAR-10数据集 <https://www.mindspore.cn/tutorials/zh-CN/r1.10/advanced/dataset/record.html#转换cifar-10数据集>`_。
|
||||
|
||||
参数:
|
||||
- **source** (str) - 待转换的CIFAR-10数据集文件所在目录的路径。
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
将CSV格式数据集转换为MindRecord格式数据集。
|
||||
|
||||
.. note::
|
||||
示例的详细信息,请参见 `转换CSV数据集 <https://www.mindspore.cn/tutorials/zh-CN/master/advanced/dataset/record.html#转换csv数据集>`_。
|
||||
示例的详细信息,请参见 `转换CSV数据集 <https://www.mindspore.cn/tutorials/zh-CN/r1.10/advanced/dataset/record.html#转换csv数据集>`_。
|
||||
|
||||
参数:
|
||||
- **source** (str) - 待转换的CSV文件路径。
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue