File:Wasserstein-GAN critic vs GAN discriminator.svg

From testwiki
Jump to navigation Jump to search
    Original file (SVG file, nominally 800 × 400 pixels, file size: 87 KB)

    This file is from Wikimedia Commons and may be used by other projects. The description on its file description page there is shown below.

    Summary

    Description
    English: Generated in Julia 1.7.2 by

    ```julia using Distributions

    μ = Normal(0, 1) ν = Normal(2, 2)

    using Roots

    cdfdiff = (x -> cdf(μ, x) - cdf(ν, x)) cdfzeros = find_zeros(cdfdiff, -5, 5)

    function optimalf(x)

       return 0.5 - 0.1*abs(x-cdfzeros[1])
    

    end

    function optimalD(x)

       return 0.4 * pdf(ν, x)/(pdf(μ, x) + pdf(ν, x))
    

    end

    function logminusoptimalD(x)

       return log(1-optimalD(x))+0.6
    

    end

    using StatsPlots using LaTeXStrings

    p1 = plot(μ; label="Generator's distribution") plot!(ν; label="reference distribution")

    1. plot!(cdfdiff; linestyle=:dashdot, label=L"CDF_{\mu} - CDF_{\nu}")

    vline!(cdfzeros; linestyle=:dashdot, label="equal CDF") plot!(optimalf;label="optimal Wasserstein critic (scaled)") plot!(optimalD; label="optimal GAN discriminator (scaled)") scene = plot(p1, size=(800,400), xlim=(-4, 4), ylim=(-0.3, 0.5), legend=:bottomright, legendfont=9)

    ```
    Date
    Source Own work
    Author Cosmia Nebula

    Licensing

    I, the copyright holder of this work, hereby publish it under the following license:
    w:en:Creative Commons
    attribution share alike
    This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
    You are free:
    • to share – to copy, distribute and transmit the work
    • to remix – to adapt the work
    Under the following conditions:
    • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
    • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.

    Captions

    Wasserstein GAN critic vs GAN discriminator

    Items portrayed in this file

    depicts

    14 July 2022

    File history

    Click on a date/time to view the file as it appeared at that time.

    Date/TimeThumbnailDimensionsUserComment
    current01:14, 15 July 2022Thumbnail for version as of 01:14, 15 July 2022800 × 400 (87 KB)wikimediacommons>Cosmia NebulaUploaded own work with UploadWizard

    There are no pages that use this file.