-
Notifications
You must be signed in to change notification settings - Fork 113
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
I run this project on Colab,Then I encounter a problem #15
Comments
Geez.... i love his work though!! i got the same problem.. was trying so hard to figure why i had this as well... Any suggestions would be very well appreciated!! |
I solve this problem by changing the path to the path that you specify , the args is in the train_options.py ,so change it and do not execute the make_ilsvrc_dataset.py |
Hi @meiguoofa !! good afternoon from Singapore!! Thank you in advance!! |
What's your error information? you should change the dataset path that you specify in the train_options.py |
heyy!!
hmm the train_options.py is as shown:
from .base_options import BaseOptions
class TrainOptions(BaseOptions):
def initialize(self, parser):
BaseOptions.initialize(self, parser)
parser.add_argument('--display_freq', type=int, default=10000,
help='frequency of showing training results on screen')
parser.add_argument('--display_ncols', type=int, default=5,
help='if positive, display all images in a single visdom web panel with
certain number of images per row.')
parser.add_argument('--update_html_freq', type=int, default=10000,
help='frequency of saving training results to html')
parser.add_argument('--print_freq', type=int, default=200,
help='frequency of showing training results on console')
parser.add_argument('--save_latest_freq', type=int, default=5000,
help='frequency of saving the latest results')
parser.add_argument('--save_epoch_freq', type=int, default=1,
help='frequency of saving checkpoints at the end of epochs')
parser.add_argument('--epoch_count', type=int, default=0, help='the
starting epoch count, we save the model by <epoch_count>,
<epoch_count>+<save_latest_freq>, ...')
parser.add_argument('--niter', type=int, default=100, help='# of
iter at starting learning rate')
parser.add_argument('--niter_decay', type=int, default=100, help='#
of iter to linearly decay learning rate to zero')
parser.add_argument('--beta1', type=float, default=0.9,
help='momentum term of adam')
parser.add_argument('--lr', type=float, default=0.0001,
help='initial learning rate for adam')
parser.add_argument('--no_lsgan', action='store_true', help='do
*not* use least square GAN, if false, use vanilla GAN')
parser.add_argument('--lambda_GAN', type=float, default=0.,
help='weight for GAN loss')
parser.add_argument('--lambda_A', type=float, default=1.,
help='weight for cycle loss (A -> B -> A)')
parser.add_argument('--lambda_B', type=float, default=1.,
help='weight for cycle loss (B -> A -> B)')
parser.add_argument('--lambda_identity', type=float, default=0.5,
help='use identity mapping. Setting
lambda_identity other than 0 has an effect of scaling the weight of the
identity mapping loss.'
'For example, if the weight of the identity
loss should be 10 times smaller than the weight of the reconstruction loss,
please set lambda_identity = 0.1')
parser.add_argument('--pool_size', type=int, default=50, help='the
size of image buffer that stores previously generated images')
parser.add_argument('--no_html', action='store_true', help='do not
save intermediate training results to [opt.checkpoints_dir]/[opt.name
]/web/')
parser.add_argument('--lr_policy', type=str, default='lambda',
help='learning rate policy: lambda|step|plateau')
parser.add_argument('--lr_decay_iters', type=int, default=50,
help='multiply by a gamma every lr_decay_iters iterations')
parser.add_argument('--avg_loss_alpha', type=float, default=.986,
help='exponential averaging weight for displaying loss')
self.isTrain = True
return parser
which part of it did u change?
…On Wed, Nov 25, 2020 at 6:49 PM meiguoofa ***@***.***> wrote:
What's your error information? you should change the dataset path that you
specify in the train_options.py
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#15 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/APZCGIVXTW43E4KQLY74ELTSRTOLVANCNFSM4SMXUBGA>
.
|
Sorry,my previous answer may be misleading to you |
Oh im almost there! i did as per instructed.. but when running python
test.py --name siggraph_caffemodel --mask_cent 0
I get:
Traceback (most recent call last):
File "test.py", line 54, in <module>
data_raw[0] = util.crop_mult(data_raw[0], mult=8)
File "/home/malcomtan/colorization-pytorch/util/util.py", line 277, in
crop_mult
return data[:,:,h:h+Hnew,w:w+Wnew]
TypeError: slice indices must be integers or None or have an __index__
method
Hmmm, may i know if u did any changes to test.py? Sorry its 11 pm here..
still trying to get it working hahahhaa xDD im so close!!
…On Wed, Nov 25, 2020 at 8:53 PM meiguoofa ***@***.***> wrote:
Sorry,my previous answer may be misleading to you
in the base_option.py parser.add_argument('--phase', type=str,
default='val', help='train_small, train, val, test, etc')
the phase change to train
and in the train.py "opt.dataroot = './dataset/ilsvrc2012/%s/' %
opt.phase" change to the dataset path that you specify
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#15 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/APZCGIX3FEIFLO3QG4GZFVLSRT46JANCNFSM4SMXUBGA>
.
|
oh yes, i realized its a numpy thing, installed many different numpy
packages!
But still to no avail! hmmm may i know what numpy version you were using?
Because now, current numpy version (1.19) doesnt support such indexing.
Just wondering if you're still able to run this repo!
So sorry for the trouble!! but yes, hope you have a good good day!! ^.^
…On Wed, Nov 25, 2020 at 10:36 PM malcolm tan ***@***.***> wrote:
Oh im almost there! i did as per instructed.. but when running python
test.py --name siggraph_caffemodel --mask_cent 0
I get:
Traceback (most recent call last):
File "test.py", line 54, in <module>
data_raw[0] = util.crop_mult(data_raw[0], mult=8)
File "/home/malcomtan/colorization-pytorch/util/util.py", line 277, in
crop_mult
return data[:,:,h:h+Hnew,w:w+Wnew]
TypeError: slice indices must be integers or None or have an __index__
method
Hmmm, may i know if u did any changes to test.py? Sorry its 11 pm here..
still trying to get it working hahahhaa xDD im so close!!
On Wed, Nov 25, 2020 at 8:53 PM meiguoofa ***@***.***>
wrote:
> Sorry,my previous answer may be misleading to you
> in the base_option.py parser.add_argument('--phase', type=str,
> default='val', help='train_small, train, val, test, etc')
> the phase change to train
> and in the train.py "opt.dataroot = './dataset/ilsvrc2012/%s/' %
> opt.phase" change to the dataset path that you specify
>
> —
> You are receiving this because you commented.
> Reply to this email directly, view it on GitHub
> <#15 (comment)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/APZCGIX3FEIFLO3QG4GZFVLSRT46JANCNFSM4SMXUBGA>
> .
>
|
Thanks, But sorry, I don’t know about this problem either , if I solve this problem later, I will discuss with you again , If u solve this problem , I hope u can tell me how to solve this problem.😄 |
yes! definitely!! im trying to solve this problem as well. But if i do, i
will DEFINITELY update you! rest assured! you have my word! ^.^
…On Thu, Nov 26, 2020 at 10:22 AM meiguoofa ***@***.***> wrote:
Thanks, But sorry, I don’t know about this problem either , if I solve
this problem later, I will discuss with you again , If u solve this problem
, I hope u can tell me how to solve this problem.😄
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#15 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/APZCGIQPP5QD7JRWJOBJRLTSRW3XVANCNFSM4SMXUBGA>
.
|
@meiguoofa hey i managed to get it working! For the 3 test.py you just need to run it in python 2.7 |
Great job!!!!! Thanks 😊 |
You're very welcome! Thank you too for helping!! ^.^
…On Thu, Nov 26, 2020 at 1:16 PM meiguoofa ***@***.***> wrote:
Great job!!!!! Thanks 😊
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#15 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/APZCGIXIF4IRMAMH2EGNH33SRXQCFANCNFSM4SMXUBGA>
.
|
The error information is No such file or directory: './dataset/ilsvrc2012/val/1/ILSVRC2012_val_00000059.JPEG',But I can find this image in the directory,Your prompt attention to my question is appreciated,Thanks for your help!!
The text was updated successfully, but these errors were encountered: