Please use Stack Overflow with the #dask tag for usage questions and github issues for bug reports
I have that:
img_new = cs[band_values]
used to be img_new(my future image result) cs(reference values, it's like an index where band_values should refer) band_values(My 2D matrix that need to be "mapped" basend on cs values)
I want to call dask_yarn.scale()
so that all the cores of my EMR cluster are used. My clusters may be launched with varying #s and types of instances so I can't hard-code scaling constants.
Do I need to calculate for myself how many cores I have (e.g. using boto3 and querying instance type info) and manage dask_yarn.scale()
or does dask_yarn
have this knowledge? Or should I use .adapt()
for this use-case?
Hello everyone
I am having the same issues that has been reported here: dask/dask-yarn#118 but on a kubernetes cluster
TLDR: The cluster dashboard is available, but when I try to open the dask workers dashboard i get a 403. My dask and distributed versions are the latest
Anyone experiencing the same problem?
dask-cuda
workload (where my functions are using jax
) and creating the workers on the command line with dask-cuda-worker --device-memory-limit=0
. However, when I look at the dashboard I see that there is still a lot of disk-write-my_gpu_function
happening. The dashboard also indicates that the workers are nowhere near the CPU memory limit. From reading the dask-cuda
docs it seems that setting the device memory limit to 0 should disable spilling, and instead the code should just OOM if the GPU runs out of memory. Is that not correct?
nvidia-smi
the GPU has 15300 MB/16160MB alloced.
--memory-limit=0
for the CUDA workers as well and report back?
Hi, I'm researching on AI and planning to get a Ensemble by running multiple model at once. Is there any example about this case?
dask.delayed can be applied in class objects?
I tried,
class BasicModel(nn.Module):
def init(self):
super(BasicModel, self).init()
self.linears1 = dask.delayed(nn.Linear)(input_dim, num_hidden)
self.linears2 = dask.delayed(nn.Linear)(num_hidden, num_hidden)
self.linears3 = dask.delayed(nn.Linear)(num_hidden, num_hidden)
self.linears4 = dask.delayed(nn.Linear)(num_hidden, output_dim)
def forward(self, x):
x = dask.delayed(F.elu)(dask.delayed(self.linears1)(x))
x = dask.delayed(F.elu)(dask.delayed(self.linears2)(x))
x = dask.delayed(F.elu)(dask.delayed(self.linears3)(x))
x=dask.delayed(self.linears4)(x)
return x
model = dask.delayed(BasicModel)().double().to(device)
model1 = dask.delayed(BasicModel)().double().to(device)
model2 = dask.delayed(BasicModel)().double().to(device)
optimizer = optim.Adam(list(model.parameters())+list(model1.parameters())+list(model2.parameters()), lr=1e-3)
then I get
''
raise TypeError("Delayed objects of unspecified length are not iterable")
TypeError: Delayed objects of unspecified length are not iterable '' at optimizer
or I'm planning
class BasicModel(nn.Module):
def init(self):
super(BasicModel, self).init()
self.set=[]
for i in range(4):
self.linears1[i] = dask.delayed(nn.Linear)(input_dim, num_hidden)
self.linears2[i] = dask.delayed(nn.Linear)(num_hidden, num_hidden)
self.linears3[i] = dask.delayed(nn.Linear)(num_hidden, num_hidden)
self.linears4[i] = dask.delayed(nn.Linear)(num_hidden, output_dim)
def forward(self, x):
y={}
for i in range(4):
temp = dask.delayed(F.elu)(dask.delayed(self.linears1)(x))
temp = dask.delayed(F.elu)(dask.delayed(self.linears2)(temp))
temp = dask.delayed(F.elu)(dask.delayed(self.linears3)(temp))
y[i]=dask.delayed(self.linears4)(temp)
x=torch.cat((y[0],y[1],y[2],y[3]),dim=1)
return x
~~ model=dask.delayed(BasicModel)()
~~loss= dask.delayed(loss_fn(pred, Y_batch) )
~~ loss.backward() .. ~ optimizer.step() ..... . can it work?..