Upgrade to Pro — share decks privately, control downloads, hide ads and more …

遺伝的FM音源

635e53b96114c922fa5486b418895960?s=47 Fadis
October 08, 2016

 遺伝的FM音源

遺伝的アルゴリズムを使って人間がパラメータを調整する事なくFM音源から意図した音色の音を出す手法を解説します
https://github.com/Fadis/genetic_fm
追記: 発表の動画を用意しました
https://www.youtube.com/watch?v=oJy0g0mt8LA

635e53b96114c922fa5486b418895960?s=128

Fadis

October 08, 2016
Tweet

More Decks by Fadis

Other Decks in Technology

Transcript

  1. Ҩ఻త'.Իݯ NAOMASA MATSUBAYASHI

  2. Ҩ఻త'.Իݯ

  3. ܭࢉػͰԻָΛԋ૗͢Δʹ͸ ͜͜Λԡ͢ ͜͏εϐʔΧʔΛ ৼಈͤ͞Δ ม׵ ͜ͷม׵͸ੲͷܭࢉػʹ͸ਏ͔ͬͨ ָේσʔλ ೾ܗσʔλ

  4. ม׵ ͜ͷม׵͸ੲͷܭࢉػʹ͸ਏ͔ͬͨ ָේσʔλ ೾ܗσʔλ ͜ͷม׵Λߦͳ͏ઐ༻ϋʔυ΢ΣΞ͕ొ৔ ήʔϜػͱ͔ʹΑ͘ࡌ͍ͬͯͨ

  5. Ի֊ͷҧ͍͸प೾਺ͷҧ͍Ͱ͋Δ υ $  Ϩ %  ϛ & 

    ϑΝ '  ι (  ϥ "  γ #  υ $ 
  6. $ $ $ $ ඵ ඵ ඵ ඵ ඵ ඵ

    ϐΞϊͷ$ͷԻͷप೾਺ղੳͷ݁Ռ $ $
  7. $ $ $ $ ඵ ඵ ඵ ඵ ඵ ඵ

    ϐΞϊͷ$ͷԻͷप೾਺ղੳͷ݁Ռ $ $ $ͷप೾਺)[෇ۙʹ εϖΫτϧઢ͕ݟΒΕΔ جԻ
  8. $ $ $ $ ඵ ඵ ඵ ඵ ඵ ඵ

    ϐΞϊͷ$ͷԻͷप೾਺ղੳͷ݁Ռ $ $ جԻͷ੔਺ഒͷप೾਺ʹ εϖΫτϧઢ͕ݟΒΕΔ ഒԻ
  9. ͜ͷύλʔϯ͕܁Γฦ͞Ε͍ͯΔ جԻ ഒԻ ഒԻ Є ͋Δؔ਺͕प೾਺Gͱͦͷ੔਺ഒͷ೾ͷΈߏ੒͞ΕΔͳΒ ͦͷؔ਺͸प೾਺Gͷपظؔ਺Ͱ͋Δ

  10. $ $ $ $ ඵ ඵ ඵ ඵ ϚϦϯόͷ$ͷԻͷप೾਺ղੳͷ݁Ռ $

    $
  11. 伴൫ͷυ͕ԡ͞Εͨ࣌఺͔Β ܗ͸ԿͰ΋ྑ͍͔Β प೾਺)[ͷपظؔ਺Λ εϐʔΧʔʹྲྀͤ͹ ԻָΛԋ૗ͨ͠ࣄʹͳΔ

  12. $$ $ $ $ ݹయతͳԻݯνοϓ͸ ϋʔυ΢ΣΞͰ؆୯ʹ࡞ΕΔपظؔ਺Λ࢖ͬͯ ԻָΛԋ૗ͨ͠

  13. ͜Ε͚ͩͰ΋ ਖ਼͍͠Ի֊Ͱԋ૗͢Δࣄ͸ग़དྷΔ Ͱ΋΋͏গ͠ ຊ෺ͷָثͬΆ͍ԻΛग़͍ͨ͠

  14. ϐΞϊ ࡾ֯೾ ͭΑ͍ ΑΘ͍ ϐΞϊͷԻ͸ ࣌ؒͱͱ΋ʹ ঃʑʹখ͘͞ͳ͍ͬͯΔ

  15. $$ $ $ $ Τϯϕϩʔϓ ໐Γ࢝Ί͔Βͷ࣌ؒʹΑͬͯ ৼ෯ΛมԽͤ͞Α͏ ͭΑ͍ ΑΘ͍

  16. ϐΞϊ ࡾ֯೾ ഒԻ͕ҧ͏ ָثͷԻ৭ͷҧ͍͸ ഒԻͷҧ͍

  17. ഒԻʹରԠ͢Δप೾਺ͷαΠϯ೾Λ ॏͶ͍͚ͯ͹ ҙਤͨ͠ഒԻ੒෼ΛؚΉԻ৭ʹͳΔ͕

  18. ഒԻ͸୔ࢁ͋Δ͔Β ·ͱΊͯίϯτϩʔϧ͢Δ࢓૊Έ͕ཉ͍͠

  19. प೾਺มௐ '. ৴߸೾ͷ೾ʹ͋Θͤͯ ൖૹ೾ͷप೾਺͕༳ΕΔ ৴߸೾ͷ෦෼ΛԻ੠৴߸ͱͯ͠ Ի੠ͷप೾਺ΑΓͣͬͱߴ͍ 7)'ଳͷप೾਺ΛТDͱͯ͠มௐ͢ΔࣄͰ Ի੠Λ7)'ଳͷి೾ʹ৐ͤͯඈ͹͢ͷ͕'.ϥδΦ ൖૹ೾ ৴߸೾

  20. Ի੠৴߸ͷৼ෯ʹґଘͤͣ ৗʹ࠷େͷৼ෯Ͱి೾Λඈ͹ͤΔ͔Β ".ϥδΦΑΓ҆ఆͨ͠඼࣭ͷԻ੠Λड͚औΕΔ प೾਺มௐ '.

  21. ৴߸೾ͷप೾਺ТTͱ ൖૹ೾ͷप೾਺ТD͕͍ۙͱ ৴߸೾͸ൖૹ೾ͷ೾ܗΛ࿪·ͤΔΑ͏ͳಇ͖Λ͢Δ प೾਺มௐ '.

  22. ৴߸೾ͷप೾਺ТTͱ ൖૹ೾ͷप೾਺ТD͕͍ۙͱ ৴߸೾͸ൖૹ೾ͷ೾ܗΛ࿪·ͤΔΑ͏ͳಇ͖Λ͢Δ ೾ܗ͕࿪ΉഒԻ੒෼͕૿ݮ͢Δ प೾਺มௐͷύϥϝʔλͷૢ࡞Ͱ ഒԻΛ·ͱΊͯίϯτϩʔϧग़དྷΔͷͰ͸ '.Իݯ

  23.       $$ $ $ $

    ЋΛม͑ͳ͕Βप೾਺ղੳΛߦͳͬͨ݁Ռ Ћ ഒԻͷେ͖͞Λௐઅ
  24. ഒ ഒ ഒ ഒ ഒ ഒ $$ $ $ $

    ТTΛม͑ͳ͕Βप೾਺ղੳΛߦͳͬͨ݁Ռ ТT ഒԻͷִؒΛௐઅ
  25. ϐΞϊͷԻ৭͸ ߴप೾੒෼΄Ͳૣ͘ݮਰ͢Δ ͜ͷ܏޲͸ ଟ͘ͷΞίʔεςΟοΫͳָثͰݟΒΕΔ

  26. ൖૹ೾ͱ৴߸೾ͷ྆ํʹΤϯϕϩʔϓΛઃ͚Δ ൖૹ೾ଆͷΤϯϕϩʔϓ͸Իྔͷ࣌ؒมԽΛදݱ ৴߸೾ଆͷΤϯϕϩʔϓ͸ഒԻͷ࣌ؒมԽΛදݱ

  27. ΦϖϨʔλ ΦϖϨʔλ ΦϖϨʔλ ΦϖϨʔλ ൖૹ೾ͱ৴߸೾ͷஈ͚ͩͱ͔ݴΘͣ Կஈ΋ॏͶΒΕΔΑ͏ʹ͢Ε͹ ΋ͬͱෳࡶͳԻ৭͕࡞ΕΔΑ

  28. $$ $ $ $ '.Իݯ ഒԻ͕࣌ؒมԽ͢Δ ΞίʔεςΟοΫͳָثͷΑ͏ͳ Ի৭Λग़ͤΔ

  29. '.Իݯ͸ ΞίʔεςΟοΫͳָثͷ ಛ௃Λগͳ͍ύϥϝʔλͰදݱग़དྷΔ ѱ͘ͳ͍ϞσϧͰ͋Δ

  30. Կނ'.Իݯ͸໓Μͩͷ͔

  31. OΦϖϨʔλͷ'.Իݯͷܭࢉࣜ OΦϖϨʔλ਺ &JΤϯϕϩʔϓ TJجԻͷप೾਺ʹର͢Δഒ཰ ЋJKΦϖϨʔλK͕ΦϖϨʔλJΛมௐ͢Δڧ͞ ЌJग़ྗʹؚ·ΕΔΦϖϨʔλJͷ৴߸ͷׂ߹

  32. Ͳ͜Λ͍ͬͨ͡Β ཉָ͍͠ثͷԻ৭ʹۙ෇͘ͷ͔ ͬ͞ͺΓΘ͔ΒΜ OΦϖϨʔλͷ'.Իݯͷܭࢉࣜ

  33. ೥୅ͷ'.ԻݯͷԻ࡞Γ͸ ख़࿅ͷ৬ਓͷΧϯΛཁ͢Δ΋ͷͰ͋ͬͨ

  34. '.ԻݯͷϘτϧωοΫ͸ ਓؒ '.ԻݯͷԻ࡞Γ͔Β ৬ਓܳΛཁΒͳ͘͠Α͏

  35. Ҩ఻త'.Իݯ

  36. ୈੈ୅ Ҩ఻తΞϧΰϦζϜ ϥϯμϜʹੜ੒ͨ͠ݸମ͔Β ༩͑ΒΕͨ৚݅ʹ ΑΓద߹͢ΔҰ෦͚ͩΛੜଘͤ͞Δ

  37. ୈੈ୅ ୈੈ୅ Ҩ఻తΞϧΰϦζϜ ੜ͖࢒ͬͨݸମͷ৘ใΛࠞͥ߹Θͤͯ ੈ୅໨Λ࡞Δ

  38. ୈੈ୅ ୈੈ୅ Ҩ఻తΞϧΰϦζϜ ੈ୅໨ͷதͰ΋ ༩͑ΒΕͨ৚݅ʹ ΑΓద߹͢ΔҰ෦͚ͩΛੜଘͤ͞Δ

  39. ୈੈ୅ ୈੈ୅ ୈੈ୅ Ҩ఻తΞϧΰϦζϜ ੜ͖࢒ͬͨݸମͷ৘ใΛࠞͥ߹Θͤͯ ੈ୅໨Λ࡞Δ

  40. ୈੈ୅ ୈੈ୅ ୈੈ୅ Ҩ఻తΞϧΰϦζϜ ͜ͷૢ࡞Λ܁Γฦ͢͜ͱʹΑͬͯ ༩͑ΒΕͨ৚݅ʹΑ͘ద߹͢ΔݸମΛ ݟ͚ͭग़͢͜ͱ͕Ͱ͖Δ

  41. '.ԻݯͷύϥϝʔλΛҨ఻ࢠͱͯ͠ '.ԻݯΛ໐Βͨ݁͠Ռͱ αϯϓϦϯάԻ͕͍ۙ ݸମΛੜଘͤ͞Ε͹ αϯϓϦϯάԻʹ͍ۙԻΛग़͢ ύϥϝʔλ͕ಘΒΕΔͷͰ͸ Իͷۙ͞ͱ͸

  42. ͜ͷͭͷԻɺฉ͖෼͚ΒΕ·͔͢ ͦͷ Ի Ի

  43. ͜ͷͭͷԻɺฉ͖෼͚ΒΕ·͔͢ ͦͷ Ի Ի

  44. ֎ࣖ தࣖ ಺ࣖ Ի ᥾ڇ ೴΁ ಛఆͷप೾਺Ͱڧ͍৴߸Λൃ͢Δ ༗ໟࡉ๔͕प೾਺ຖʹ୔ࢁฒΜͰ͍Δ प೾਺ຖͷ ৼ෯ͷେ͖͞

    ޑບͱ೴ͷؒʹ͸ प೾਺ྖҬ΁ͷม׵͕ ڬ·͍ͬͯΔ
  45. ਓؒͷௌ֮͸ ֤प೾਺ͷ೾ͷৼ෯͚ͩΛฉ͍͍ͯͯ Ґ૬Λฉ͍͍ͯͳ͍ ྘ͷഒԻͷҐ૬͕ͣΕ͍ͯΔ͕ ͦͷࣄΛ஌֮͢Δࣄ͸ग़དྷͳ͍

  46. ͜ͷͭͷԻɺฉ͖෼͚ΒΕ·͔͢ ͦͷ Ի Ի

  47. ͜ͷͭͷԻɺฉ͖෼͚ΒΕ·͔͢ ͦͷ Ի Ի

  48. ͍ۙԻͱ͸ ಉ࣌ؒ͡ଳʹ ಉ͡Α͏ͳ೾ܗʹͳ͍ͬͯΔԻ ಉ࣌ؒ͡ଳʹ ಉ͡Α͏ͳप೾਺ͷ೾ΛؚΜͰ͍ΔԻ

  49. Ҩ఻తΞϧΰϦζϜ͸ ޯ഑ͷແ͍ॴͰ͸ϥϯμϜͳࢼߦʹͳΔ ͜͜ʹ εϖΫτϧઢ͕ग़ΔԻ΋ ͜͜ʹ εϖΫτϧઢ͕ग़ΔԻ΋ ͲͪΒ΋໨తؔ਺ͱશ͘ҟͳΔͨΊಉ͡దԠ౓

  50. Ҩ఻తΞϧΰϦζϜ͸ ޯ഑ͷແ͍ॴͰ͸ϥϯμϜͳࢼߦʹͳΔ ָثͷԻ৭ͷεϖΫτϧ͸ ݶΒΕͨप೾਺ʹύϧεঢ়ʹݱΕΔҝ ୯७ʹεϖΫτϧը૾ಉ࢜ͷൺֱΛߦͳ͏ͱ Ҩ఻తΞϧΰϦζϜ͕ ہॴ࠷దղʹऩଋ͠΍͘͢ͳΔ

  51. ஈ֊໨ ஈ֊໨ ஈ֊໨ ஈ֊໨ ஈ֊໨ ஈ֊໨ ஈ֊໨ ࠷ॳ͸෼ղೳͷ௿͍ प೾਺ղੳͰ ൺֱΛߦͳ͏

    ݱࡏͷ෼ղೳͰ ࠷େదԠ౓͕Ұఆճ਺ ߋ৽͞Εͳ͔ͬͨΒ ࣍ͷ෼ղೳʹਐΉ
  52. αϯϓϦϯάԻΛप೾਺ղੳ ϥϯμϜͳҨ఻ࢠΛੜ੒ ֤Ҩ఻ࢠΛ'.ԻݯͰԋ૗ ֤Ҩ఻ࢠͷԻΛप೾਺ղੳ Ұ༷ަ伹ͱಥવมҟͰҨ఻ࢠΛੜ੒ αϯϓϦϯάԻͱͷڑ཭Λܭࢉ ϧʔϨοτબ୒ͰݸମΛݫબ ࠷େ෼ղೳͰ ্ҐʹมԽ͕ݟΒΕͳ͍ ͸͍

    ͍͍͑ ෼ղೳΛ্͛Δ͔Ͳ͏͔Λ൑அ
  53. αϯϓϦϯάԻΛप೾਺ղੳ ϥϯμϜͳҨ఻ࢠΛੜ੒ ֤Ҩ఻ࢠΛ'.ԻݯͰԋ૗ ֤Ҩ఻ࢠͷԻΛप೾਺ղੳ Ұ༷ަ伹ͱಥવมҟͰҨ఻ࢠΛੜ੒ αϯϓϦϯάԻͱͷڑ཭Λܭࢉ ϧʔϨοτબ୒ͰݸମΛݫબ ࠷େ෼ղೳͰ ্ҐʹมԽ͕ݟΒΕͳ͍ ͸͍

    ͍͍͑ ෼ղೳΛ্͛Δ͔Ͳ͏͔Λ൑அ αϯϓϦϯάԻ͕ ։࢝ԿඵͰ伴൫Λԡͯ͠ /05&0/  ։࢝ԿඵͰ伴൫Λ཭ͨ͠ͷ͔ /05&0''  ͷ৘ใ͕ແ͍ͱಉ͡Α͏ʹԋ૗Ͱ͖ͳ͍
  54. ੺τϥϯϖοτͷΤϯϕϩʔϓ ྘੺Λ࣌ؒඍ෼ͨ͠΋ͷ ੨ऴ୺͔Βͷc྘cͷ࠷খ஋ͱऴ୺͔Βͷڑ཭ͷੵ

  55. ੨͕࠷େʹͳΔ ໼ҹͷҐஔΛ/05&0''ͱ͢Δ

  56. αϯϓϦϯάԻΛप೾਺ղੳ ϥϯμϜͳҨ఻ࢠΛੜ੒ ֤Ҩ఻ࢠΛ'.ԻݯͰԋ૗ ֤Ҩ఻ࢠͷԻΛप೾਺ղੳ Ұ༷ަ伹ͱಥવมҟͰҨ఻ࢠΛੜ੒ αϯϓϦϯάԻͱͷڑ཭Λܭࢉ ϧʔϨοτબ୒ͰݸମΛݫબ ࠷େ෼ղೳͰ ্ҐʹมԽ͕ݟΒΕͳ͍ ͸͍

    ͍͍͑ ෼ղೳΛ্͛Δ͔Ͳ͏͔Λ൑அ
  57. '.ԻݯͰԋ૗ MPHεέʔϧʹม׵ ը૾Λൺֱ ΤϯϕϩʔϓΛൺֱ ೾ܗσʔλ '.Իݯͷύϥϝʔλ ϑʔϦΤม׵ ࣌ࠁຖʹ૯࿨ΛͱΔ Իྔͷ࣌ؒมԽ ࣌ؒຖͷεϖΫτϧ

    εϖΫτϧը૾ प೾਺੒෼ͷͣΕ Իྔͷ࣌ؒมԽͷͣΕ Ի৭ͷڑ཭
  58. ࣮ࡍͷαοΫεͷԻ

  59. ੈ୅໨ ࣮ࡍͷαοΫεͷԻ

  60. ੈ୅໨ ࣮ࡍͷαοΫεͷԻ

  61. ੈ୅໨ ࣮ࡍͷαοΫεͷԻ

  62. ੈ୅໨ ࣮ࡍͷαοΫεͷԻ

  63. ੈ୅໨ ࣮ࡍͷαοΫεͷԻ

  64. ࣮ࡍͷαοΫεͷԻ ੈ୅໨

  65. ࣮ࡍͷαοΫεͷԻ ੈ୅໨

  66. ࣮ࡍͷαοΫεͷԻ ੈ୅໨

  67. ࣮ࡍͷαοΫεͷԻ ੈ୅໨

  68. ࣮ࡍͷαοΫεͷԻ ੈ୅໨

  69. ࣮ࡍͷαοΫεͷԻ ੈ୅໨

  70. ࣮ࡍͷαοΫεͷԻ ੈ୅໨

  71. ࣮ࡍͷαοΫεͷԻ ੈ୅໨

  72. ࣮ࡍͷαοΫεͷԻ ੈ୅໨

  73. αϯϓϦϯάԻΛप೾਺ղੳ ϥϯμϜͳҨ఻ࢠΛੜ੒ ֤Ҩ఻ࢠΛ'.ԻݯͰԋ૗ ֤Ҩ఻ࢠͷԻΛप೾਺ղੳ Ұ༷ަ伹ͱಥવมҟͰҨ఻ࢠΛੜ੒ αϯϓϦϯάԻͱͷڑ཭Λܭࢉ ϧʔϨοτબ୒ͰݸମΛݫબ ࠷େ෼ղೳͰ ্ҐʹมԽ͕ݟΒΕͳ͍ ͸͍

    ͍͍͑ ෼ղೳΛ্͛Δ͔Ͳ͏͔Λ൑அ
  74. ԣҰྻ෼ΛٻΊΔͷʹճͷ཭ࢄϑʔϦΤม׵ ͦΕΛ࣌ؒํ޲ͷ෼ղೳ෼͚ͩ ͦΕΛݸମ਺෼ ͦΕΛղ͕ऩଋ͢Δ·Ͱ൓෮ ΋ͷੌ͕͔͔࣌ؒ͘Δ

  75. $ ./find_fm_params -i ./Piano.mf.C3.aiff -o out -n 36! real 1681m6.281s!

    user 6494m54.098s! sys 72m33.467s! $ ࣌ؒ෼ඵ 04 (FOUPP-JOVYY@ MJOVY ίϯύΠϥ ($$ ''5ʹ࢖༻ͨ͠ϥΠϒϥϦ ''58 ୯ਫ਼౓ɺ0QFO.1ରԠɺ"79ରԠ $16 *OUFM$PSFJ 4LZMBLF ()[ίΞ ϝϞϦ (# αϯϓϦϯάσʔλͷ௕͞ ඵ L)[ ऴྃ৚݅ ੈ୅໨ΛٻΊͨΒऴྃ
  76. Կͱ͔ͯ͠଎͘Ͱ͖ͳ͍͔

  77. ܭࢉࢿݯͷ๫ྗͰղܾ

  78. '.ԻݯͰԋ૗ MPHεέʔϧʹม׵ ը૾Λൺֱ ΤϯϕϩʔϓΛൺֱ ೾ܗσʔλ '.Իݯͷύϥϝʔλ ϑʔϦΤม׵ ࣌ࠁຖʹ૯࿨ΛͱΔ Իྔͷ࣌ؒมԽ ࣌ؒຖͷεϖΫτϧ

    εϖΫτϧը૾ प೾਺੒෼ͷͣΕ Իྔͷ࣌ؒมԽͷͣΕ Ի৭ͷڑ཭
  79. '.ԻݯͰԋ૗ MPHεέʔϧʹม׵ ը૾Λൺֱ ΤϯϕϩʔϓΛൺֱ ೾ܗσʔλ '.Իݯͷύϥϝʔλ ϑʔϦΤม׵ ࣌ࠁຖʹ૯࿨ΛͱΔ Իྔͷ࣌ؒมԽ ࣌ؒຖͷεϖΫτϧ

    εϖΫτϧը૾ प೾਺੒෼ͷͣΕ Իྔͷ࣌ؒมԽͷͣΕ Ի৭ͷڑ཭ (1(16ͷమଇ (16͕σʔλΛॲཧ͢Δ଎͞ʹରͯ͠ 1$*&YQSFTT͸஗͍ ͜͜Λ௨Δσʔλ͸࠷খݶʹ
  80. '.ԻݯͰԋ૗ MPHεέʔϧʹม׵ ը૾Λൺֱ ΤϯϕϩʔϓΛൺֱ ೾ܗσʔλ '.Իݯͷύϥϝʔλ ϑʔϦΤม׵ ࣌ࠁຖʹ૯࿨ΛͱΔ Իྔͷ࣌ؒมԽ ࣌ؒຖͷεϖΫτϧ

    εϖΫτϧը૾ प೾਺੒෼ͷͣΕ Իྔͷ࣌ؒมԽͷͣΕ Ի৭ͷڑ཭ (1(16ͷమଇ (16͸4*.%ͷԽ͚෺ ฒྻ౓ΛՔ͕ͳ͍ͱੑೳ͕ग़ͳ͍ QBSBMMFMPSEJF
  81. '.ԻݯͰԋ૗ MPHεέʔϧʹม׵ ը૾Λൺֱ ΤϯϕϩʔϓΛൺֱ ೾ܗσʔλ '.Իݯͷύϥϝʔλ ϑʔϦΤม׵ ࣌ࠁຖʹ૯࿨ΛͱΔ Իྔͷ࣌ؒมԽ ࣌ؒຖͷεϖΫτϧ

    εϖΫτϧը૾ प೾਺੒෼ͷͣΕ Իྔͷ࣌ؒมԽͷͣΕ Ի৭ͷڑ཭ খ͍͞ খ͍͞
  82. '.ԻݯͰԋ૗ MPHεέʔϧʹม׵ ը૾Λൺֱ ΤϯϕϩʔϓΛൺֱ ೾ܗσʔλ '.Իݯͷύϥϝʔλ ϑʔϦΤม׵ ࣌ࠁຖʹ૯࿨ΛͱΔ Իྔͷ࣌ؒมԽ ࣌ؒຖͷεϖΫτϧ

    εϖΫτϧը૾ प೾਺੒෼ͷͣΕ Իྔͷ࣌ؒมԽͷͣΕ Ի৭ͷڑ཭ ϦϦʔε΍ΞλοΫΛਪఆ͢Δʹ͸ Իྔͷ࣌ؒมԽΛઢܗʹᢞΊΔඞཁ͕͋Γ ฒྻԽʹ޻෉͕ཁΓͦ͏
  83. '.ԻݯͰԋ૗ MPHεέʔϧʹม׵ ը૾Λൺֱ ΤϯϕϩʔϓΛൺֱ ೾ܗσʔλ '.Իݯͷύϥϝʔλ ϑʔϦΤม׵ ࣌ࠁຖʹ૯࿨ΛͱΔ Իྔͷ࣌ؒมԽ ࣌ؒຖͷεϖΫτϧ

    εϖΫτϧը૾ प೾਺੒෼ͷͣΕ Իྔͷ࣌ؒมԽͷͣΕ Ի৭ͷڑ཭ ϧʔϓόοΫ෇͖ͷ'.Իݯ͸ ࣌ࠁUͷ஋Λܾఆ͢Δҝʹ ࣌ࠁUͷΦϖϨʔλͷঢ়ଶ͕ඞཁʹͳΔͨΊ ฒྻԽʹ޻෉͕ཁΓͦ͏
  84. '.ԻݯͰԋ૗ MPHεέʔϧʹม׵ ը૾Λൺֱ ΤϯϕϩʔϓΛൺֱ ೾ܗσʔλ '.Իݯͷύϥϝʔλ ϑʔϦΤม׵ ࣌ࠁຖʹ૯࿨ΛͱΔ Իྔͷ࣌ؒมԽ ࣌ؒຖͷεϖΫτϧ

    εϖΫτϧը૾ प೾਺੒෼ͷͣΕ Իྔͷ࣌ؒมԽͷͣΕ Ի৭ͷڑ཭ େ͖͍ খ͍͞ ͦͦ͜͜ ฒྻԽ͕؆୯ͦ͏ͳ ੺ઢͷൣғΛ(16ʹ΍ͬͯ΋Β͏
  85. '.ԻݯͰԋ૗ MPHεέʔϧʹม׵ ը૾Λൺֱ ΤϯϕϩʔϓΛൺֱ ೾ܗσʔλ '.Իݯͷύϥϝʔλ ϑʔϦΤม׵ ࣌ࠁຖʹ૯࿨ΛͱΔ Իྔͷ࣌ؒมԽ ࣌ؒຖͷεϖΫτϧ

    εϖΫτϧը૾ प೾਺੒෼ͷͣΕ Իྔͷ࣌ؒมԽͷͣΕ Ի৭ͷڑ཭ OWJEJBۘ੡ͷ''5ϥΠϒϥϦDV⒎UͰย෇͚Δ
  86. __device__ void output_comp_cb(! void *dataOut, size_t offset, cufftComplex element,! void

    *callerInfo, void *sharedPtr! ) {! fft_detail *detail = (fft_detail*)callerInfo;! const size_t index =! offset % ( (detail->resolution/2) + 1 );! const size_t batch =! detail->batch_offset + offset /! ( (detail->resolution/2) + 1 );! if( index < detail->width ) {! if( batch < detail->reference_batch_count ) {! const float value = cuCabsf( element );! atomicAdd( detail->envelope + batch, value );! const float log_value_ =! 80.f * __log10f( value < 1.f ? 1.f : value );! const int log_value =! log_value_ > 255.f ?! int( 255 ) : int( log_value_ );! atomicAdd( &detail->diff, float( __sad(! log_value,! int( detail->reference[ index + detail->width * batch ] ),! 0! ) ) );! }! else {! ''5ޙͷग़ྗʹίʔϧόοΫΛઃఆ
  87. void *dataOut, size_t offset, cufftComplex element,! void *callerInfo, void *sharedPtr!

    ) {! fft_detail *detail = (fft_detail*)callerInfo;! const size_t index =! offset % ( (detail->resolution/2) + 1 );! const size_t batch =! detail->batch_offset + offset /! ( (detail->resolution/2) + 1 );! if( index < detail->width ) {! if( batch < detail->reference_batch_count ) {! const float value = cuCabsf( element );! atomicAdd( detail->envelope + batch, value );! const float log_value_ =! 80.f * __log10f( value < 1.f ? 1.f : value );! const int log_value =! log_value_ > 255.f ?! int( 255 ) : int( log_value_ );! atomicAdd( &detail->diff, float( __sad(! log_value,! int( detail->reference[ index + detail->width * batch ] ),! 0! ) ) );! }! else {! const float value = cuCabsf( element );! Իྔͷ࣌ؒมԽʹݱࡏͷ஋ΛՃࢉ
  88. ) {! fft_detail *detail = (fft_detail*)callerInfo;! const size_t index =!

    offset % ( (detail->resolution/2) + 1 );! const size_t batch =! detail->batch_offset + offset /! ( (detail->resolution/2) + 1 );! if( index < detail->width ) {! if( batch < detail->reference_batch_count ) {! const float value = cuCabsf( element );! atomicAdd( detail->envelope + batch, value );! const float log_value_ =! 80.f * __log10f( value < 1.f ? 1.f : value );! const int log_value =! log_value_ > 255.f ?! int( 255 ) : int( log_value_ );! atomicAdd( &detail->diff, float( __sad(! log_value,! int( detail->reference[ index + detail->width * batch ] ),! 0! ) ) );! }! else {! const float value = cuCabsf( element );! atomicAdd( detail->envelope + batch, value );! const float log_value_ =! 80.f * __log10f( value < 1.f ? 1.f : value );! ϦϑΝϨϯεͷεϖΫτϧը૾ͱͷ ͣΕΛٻΊͯڑ཭ʹՃࢉ
  89. $ ./find_fm_params -i ./Piano.mf.C3.aiff -o out -n 36! real 145m51.199s!

    user 126m37.108s! sys 18m57.556s! $ ࣌ؒ෼ඵ 04 (FOUPP-JOVYY@ MJOVY ίϯύΠϥ OWDD ''5ʹ࢖༻ͨ͠ϥΠϒϥϦ $V''5 $16 *OUFM$PSFJ 4LZMBLF ()[ίΞ (16 OWJEJB(F'PSDF(59()[$6%"ίΞ ϝϞϦ IPTU(#EFWJDF(# αϯϓϦϯάσʔλͷ௕͞ ඵ L)[ ऴྃ৚݅ ੈ୅໨ΛٻΊͨΒऴྃ
  90. ຊ෺ͷϑϧʔτͷԻ '.ԻݯͷϑϧʔτͷԻ

  91. ຊ෺ͷτϥϯϖοτͷԻ '.ԻݯͷτϥϯϖοτͷԻ

  92. ຊ෺ͷϐΞϊͷԻ '.ԻݯͷϐΞϊͷԻ

  93. ·ͱΊ Ҩ఻తΞϧΰϦζϜͰ '.ԻݯͷύϥϝʔλΛٻΊΔ ৬ਓܳ͸ཁΒͳ͍ ཁΔͷ͸(16 ͜Ε͕ੈلͷ'.Իݯͷ࢖͍ํ