Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up and add docs for BigGAN demo #1038

Merged
merged 8 commits into from
Jun 23, 2021

Conversation

AzizZayed
Copy link
Contributor

Description

Remove all unnecessary classes from the BigGAN demo and reduced it from 5 to 3 files. I used an array as input to the translator instead of a sample-size parameter. I input the 'truncation' parameter as an argument in the criteria. Thus, the translator only needs to take an integer array of category-IDs.

@codecov-commenter
Copy link

codecov-commenter commented Jun 18, 2021

Codecov Report

Merging #1038 (6c076c6) into master (f80f395) will increase coverage by 0.26%.
The diff coverage is 31.25%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #1038      +/-   ##
============================================
+ Coverage     69.99%   70.25%   +0.26%     
- Complexity     5109     5170      +61     
============================================
  Files           504      509       +5     
  Lines         22613    23125     +512     
  Branches       2372     2431      +59     
============================================
+ Hits          15828    16247     +419     
- Misses         5518     5571      +53     
- Partials       1267     1307      +40     
Impacted Files Coverage Δ
...i/djl/modality/cv/translator/BigGANTranslator.java 26.66% <26.66%> (ø)
api/src/main/java/ai/djl/Application.java 57.69% <100.00%> (+0.82%) ⬆️
...ain/java/ai/djl/modality/cv/util/NDImageUtils.java 48.68% <0.00%> (-14.48%) ⬇️
...ai/djl/tensorflow/engine/javacpp/JavacppUtils.java 67.74% <0.00%> (-9.56%) ⬇️
...src/main/java/ai/djl/modality/Classifications.java 84.31% <0.00%> (-5.89%) ⬇️
.../main/java/ai/djl/serving/wlm/WorkLoadManager.java 64.76% <0.00%> (-5.72%) ⬇️
.../main/java/ai/djl/paddlepaddle/engine/PpModel.java 82.35% <0.00%> (-5.15%) ⬇️
...rc/main/java/ai/djl/paddlepaddle/jni/JniUtils.java 85.00% <0.00%> (-4.48%) ⬇️
.../src/main/java/ai/djl/repository/zoo/Criteria.java 86.33% <0.00%> (-0.33%) ⬇️
.../main/java/ai/djl/tensorflow/engine/TfNDArray.java 85.23% <0.00%> (ø)
... and 16 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f80f395...6c076c6. Read the comment docs.

@AzizZayed AzizZayed changed the title Clean up BigGAN demo Clean up and add docs for BigGAN demo Jun 20, 2021
@frankfliu
Copy link
Contributor

Let's put the images in our resources s3 bucket.

@AzizZayed AzizZayed force-pushed the biggan-cleanup branch 3 times, most recently from 6e052e9 to d57fbbf Compare June 21, 2021 20:35

Black Swan | Golden Retriever | Bubble | Alp | Cheeseburger
:-------------------------:|:-------------------------: |:-------------------------: | :----------------------: | :----------------------:
![](https://djl-ai.s3.amazonaws.com/resources/images/biggan/black-swan.png) | ![](https://djl-ai.s3.amazonaws.com/resources/images/biggan/golden-retriever.png)| ![](https://djl-ai.s3.amazonaws.com/resources/images/biggan/bubble.png) | ![](https://djl-ai.s3.amazonaws.com/resources/images/biggan/hills.png) | ![](https://djl-ai.s3.amazonaws.com/resources/images/biggan/cheeseburger.png)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@@ -181,6 +181,9 @@ public int hashCode() {
* String}&gt;.
*/
Application WORD_RECOGNITION = new Application("cv/word_recognition");

/** An application that accepts a seed and returns generated images. */
Application GAN = new Application("cv/gan");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe use Generator instead. A GAN is a technique and an Application is supposed to be a problem

Copy link
Contributor Author

@AzizZayed AzizZayed Jun 23, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about "GENERATION" to keep with the standard in Application?

@frankfliu frankfliu merged commit 6a81d9d into deepjavalibrary:master Jun 23, 2021
@AzizZayed AzizZayed deleted the biggan-cleanup branch June 23, 2021 16:44
Lokiiiiii pushed a commit to Lokiiiiii/djl that referenced this pull request Oct 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants