Closed whitleyo closed 5 years ago
This is weird, can you send me the MOFA object (before training) via Slack channel?
I replied to you via Slack channel. Can you confirm if the problem is solved?
I copy paste the response here for other users:
the error should be fixed in the last commit, it was a numerical round-off error. Can you pull, re-install the python package* and try again?
Yet, the behaviour of shutting off factors when convergence is clearly reached is very unusual, it usually happens before that. With the new commit I achieve convergence with small tolerance, but it takes quite some time (>5000 iterations). To speed it up I would recommend training with less factors, and perhaps just fix them (TrainOptions$DropFactorThreshold = 0) to something like 10 or 15 . I often struggle to get interpretable factors beyond the ~15th, and as in PCA, the choice of the number of factors is always a bit arbitrary
Hi,
It appears that I'm no longer having this issue. For a single run I couldn't get convergence to happen in 10,000 iterations, but the error I was having previously is gone.
Thanks, Owen
As I mentioned in the previous comment, do you have convergence issues even when trying with less factors? Otherwise you can just set the convergence threshold to ~2. From the variance explained plot the fit seems very good.
Hi,
When I set the convergence threshold to 2, for 15 factors, using the dataset I sent, I can obtain convergence in about 28 minutes. When I set the convergence threshold to 1.0, I do not obtain convergence within 10^6 iterations, which takes place over 2 days. Looking at the model output, I see that getELBO(MOFA.obj) gives NaN.
Something I noticed with using multiple runs with different seeds was that the solutions found were inconsistent, i.e. latent factors discovered were generally uncorrelated. Settings in that case were a tolerance of 1.0, maxiter = 5000, and 10 runs with different seeds.
Github isn't accepting R notebook html output so I can send you that document in the slack if you'd like.
Thanks again for all your help.
Hi, this is a very weird case that I have never come across with. The models are indeed very inconsistent and I will need to dig in more closely to find out what is happening. Can you send me the details via slack?
P.S. How does the factor robustness plot look like with a high tolerance threshold (>1.0)?
Thanks.
Hi,
I'm trying to run MOFA with GISTIC CNV data and vst transformed RNA-seq data (DESEQ2), and if I set the dropfactor threshold to 0.01 and tolerance to 1.0 for TrainingOptions, at some point, I can see in the output there's an endless dropping of factors until none are left. If I set the tolerance to 5.0 then the model converges.
From the output, I can see that the model appears to converge with deltaElbow ~2-5, and at some point a few jumps occur. Any idea/suggestions of how to handle this issue?
Other relevant information is that I played around with 20 factors, setting the tolerance to 5 and MOFA managed to find structure in the data.
Here's a subset of the code that failed
And the SessionInfo
Here's a snippet of the output:
And the point of failure