Giter Club home page Giter Club logo

argus's People

Contributors

lromul avatar nickveld avatar nikolasent avatar sankovalev avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

argus's Issues

Handle multi-GPU model

I am training a model on 4 different GPUs. During the training, I use the MonitorCheckpoint callback for saving the model on disk. Due to long training time, my script stops after training. The test is performed by hand, reinitializing a python kernel and loading the trained model.

The loading is performed with model = argus.load_model() and, by printing the model variable, I can see the 4 devices I used in training. However, I would like to move the model to a single GPU for the tensor operations I need to perform must be on the same device. Indeed I got:
RuntimeError: Expected all tensors to be on the same device, but found at least two devices, cuda:2 and cuda:0!

Is there any way to re-assign the cuda device? Using model.set_device(0) does not work, I can see all the previous GPU running.

Thanks in advance, and congratulations for the package!

How to use model that using output from another model?

Hey, I am currently facing a problem using argus when trying to use multiple model (resnet then pspnet).
It's fine when I'm doing it conventionally but got error TypeError: forward() missing 1 required positional argument when using argus.

the model that I meant is something like this :

class PSPNet(nn.Module):
    def __init__(self,in_ch=1,nb_classes=6,bins=(1, 2, 3, 6)):
        super(PSPNet,self).__init__()
        fea_dim = 128
        self.prev_model= resnet(in_ch,nb_classes) #feature map extract
        self.ppm = PPM(fea_dim, int(fea_dim/len(bins)), bins)
        self.cls = nn.Sequential(
            nn.Conv2d(fea_dim*2, 64, kernel_size=3, padding=1, bias=False),
            nn.BatchNorm2d(64),
            nn.ReLU(inplace=True),
            nn.Conv2d(64, nb_classes, kernel_size=1)
        )
    def forward(self,x):
        x = self.prev_model(x)
        x = self.ppm(x)
        x = self.cls(x)
        return x

class resnet(nn.Module):
       blabla

Any recommendation?
thanks.

Consider infinite num_epochs

Currently the default num_epochs is 1 and there is no support for the infinite num_epochs (using -1 for example).

num_epochs: int = 1,

while self.state.epoch < end_epoch and not self.state.stopped:

What about this feature for the "I do not know how many epochs I need, I just want to provide the EarlyStopping callback or stop the training with KeyboardInterrupt".

Checking that either num_epochs > 0 or EarlyStopping_instance in callbacks is a valid option.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.