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

Bug fix for: "ImportError: cannot import name 'FileWriter' from 'tensorboard'" #29

Open
wants to merge 90 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
90 commits
Select commit Hold shift + click to select a range
f18de8a
Bug fix for
May 5, 2023
c59afae
Support for Python3.8 and Python 2.7
May 5, 2023
1fef73c
- A script to generate custom dataset for StackGAN
May 9, 2023
72b0aad
- generate custome dataset: filenames, classids
soumentechnoexponent May 10, 2023
07a6117
- filenames and embedding is created
May 10, 2023
6bc6321
- Proper embeddings, classids, and filenames are generated
May 11, 2023
55fb7ca
- Stage-1 and Stage-2 ran successfully
May 12, 2023
4799fba
- code cleanup
May 15, 2023
8666e6f
- install fasttext through conda
May 15, 2023
b0f5e17
install pytorch through conda
May 15, 2023
ba7c4c5
- Doc update
May 16, 2023
e7bad61
- script to check CUDA
May 16, 2023
6737182
- script to check CUDA support version
May 16, 2023
af3aaa3
- Cuda checks
May 19, 2023
39f7e6f
- Generate data form sqlite
May 19, 2023
b7e3c82
-pascal voc tool update
May 19, 2023
f2b27b7
- generate dataset form sqlite
May 19, 2023
d7fbb14
configuration for Sixray500 stage-1
May 19, 2023
14f378d
configuration for Sixray500 stage-2
May 19, 2023
2fa9fef
Retraining configuration for stage-1 with 1000 epoch
May 19, 2023
730de24
Retraining configuration for stage-2 with 1000 epoch
May 19, 2023
e4ef52f
Retraining configuration for stage-2 with 1000 epoch
May 19, 2023
a04ff37
configuration for 600 captions
May 19, 2023
0b97033
Stop config for finetune
May 19, 2023
fa2761b
Config for stage-2 600 captions
May 19, 2023
e81d89b
Experiment-3 1107 captions and 432 files
May 22, 2023
29705d2
Experiment-3 1107 captions and 432 files, stage-2
May 22, 2023
7dcabf1
Trainer image logging update
May 22, 2023
c307aa3
Setup config for experiment-3
May 22, 2023
d0d93e6
- support to train fasttext on caption dataset
May 23, 2023
77b4fd2
- Updating scripts and configuration
May 23, 2023
1cd65cc
- save image at last epoch
May 23, 2023
dc4f39d
- config for stage -1
May 23, 2023
2b8271a
- config for stage -2
May 23, 2023
9f39fd7
- config for stage -1 for 1347 captions
May 24, 2023
cf41c01
- one script for entire pipeline
May 24, 2023
5e6ba5b
- generate test dataset
soumentechnoexponent May 25, 2023
19eacbb
- testing script
soumentechnoexponent May 25, 2023
d46deaf
- script update to generate data with fasttext encoding
May 25, 2023
7ec642c
- config update for express train and test
May 25, 2023
cbe8d8c
- increase epoch form 1 to 500
May 25, 2023
a827877
- script generation update
May 26, 2023
5cf8a42
Preparing for training with 2183 caption 1000D
May 26, 2023
0ab31e1
- config for 2500 captions
May 29, 2023
c5d5af2
- Fasttext algorithm change
May 29, 2023
7b7ffc5
- Aspect ratio resize transform
May 29, 2023
58bafec
- cbow 2048D, 200 epoch, zdim 200
May 29, 2023
ad61d1e
- resize bug fix
May 29, 2023
5829e84
- config for cbow1024D no crop 2500 caption and zdim 100
May 30, 2023
0a12f0d
- minimum caption length=3
May 30, 2023
fffbd1e
- script update foe experiment 11: sixray_2500_ftt_1024D_skipgram_nocrop
Jun 1, 2023
33f7e1a
WIP for openai access
Jun 1, 2023
b277140
Bulk OpenAPI embedding text processor
Jun 1, 2023
ce01d5d
- bulk caption loading
Jun 2, 2023
30d7183
- single caption loading
Jun 2, 2023
c01ca24
- Embedding and POC with OpenAI is done
Jun 2, 2023
65022cf
- file check in progress
Jun 2, 2023
310d355
- config update for openai embedding
Jun 2, 2023
9695908
- FP32 to FP64 auto adaption
Jun 3, 2023
c7660bb
- experiment12
Jun 3, 2023
4708a20
texts to captions
Jun 3, 2023
af0752b
texts to captions
Jun 3, 2023
fd44939
- ready for experiment12
Jun 3, 2023
e82cee4
run with 1000 epoch openai embeddings
Jun 3, 2023
41b47ec
ignore pycache
Jun 3, 2023
86d44f2
floating point precision control
Jun 3, 2023
bf1f3ca
11805 caption and 2381 images is available
Jun 8, 2023
d0fb9cc
config update for 2381 images
Jun 8, 2023
a9e4fe5
Prepare for SQLite data generation
Jun 8, 2023
a049450
32 batch size
Jun 8, 2023
a3b6717
16 batch size
Jun 8, 2023
c31192a
64 batch size
Jun 8, 2023
a40a7b6
epoch 1000
Jun 8, 2023
ec7d45a
- Generate test images during training
Jun 8, 2023
c859f7e
- CUDA clean in test phase
Jun 8, 2023
aff251d
- PYTORCH_CUDA_ALLOC_CONF
Jun 8, 2023
c9d4d3b
- bug fix during memory cleaning
Jun 8, 2023
1bd338e
Fixing CUDA PyTorch Future deprecation waring
Jun 8, 2023
fc46af1
- capping captions to 4 as a few files are inconsistently contains up…
soumentechnoexponent Jun 9, 2023
fc7804d
- Hyperparameter double
Jun 12, 2023
d70f377
- Hyperparameter double
Jun 12, 2023
3afcf2b
- copy config
Jun 12, 2023
50aeb70
- copy config
Jun 12, 2023
213f178
- Finetune Experiment15.
Jun 13, 2023
58f1e98
- fix memory count
Jun 13, 2023
53e3081
- mild code update for WorkRNN models
Jul 7, 2023
fcb0a58
- saving git checksum and generating a config
Jul 8, 2023
ac85b9d
- config update
Jul 8, 2023
c961de2
buf gix
Jul 8, 2023
42dbacf
config for cnn-rnn word embedding
Jul 10, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# StackGAN-pytorch
Original Repository [hanzhanggit/StackGAN-Pytorch](https://github.com/hanzhanggit/StackGAN-Pytorch)

- [Tensorflow implementation](https://github.com/hanzhanggit/StackGAN)

- [Inception score evaluation](https://github.com/hanzhanggit/StackGAN-inception-model)
Expand All @@ -11,17 +13,20 @@ Pytorch implementation for reproducing COCO results in the paper [StackGAN: Text


### Dependencies
python 2.7
python 2.7 or higher

Pytorch
Base Deeplearning Framework: `Pytorch`

In addition, please add the project folder to PYTHONPATH and `pip install` the following packages:
- `tensorboard`
- `tensorboardX`
- `python-dateutil`
- `easydict`
- `pandas`
- `torchfile`

**Or** use the following command `pip install -r requirements.txt`
Copy link
Author

Choose a reason for hiding this comment

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

Guidance to install the dependencies using a single command as I have introduced a requirements.txt file




**Data**
Expand Down
2 changes: 1 addition & 1 deletion code/trainer.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
from miscc.utils import compute_discriminator_loss, compute_generator_loss

from tensorboard import summary
from tensorboard import FileWriter
from tensorboardX import FileWriter
Copy link
Author

Choose a reason for hiding this comment

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

Importing the library to fix the bug



class GANTrainer(object):
Expand Down
6 changes: 6 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
tensorboard==2.13.0
tensorboardX==2.6
python-dateutil
easydict==1.10
pandas==1.5.1
torchfile==0.1.0