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

installation problem #51

Closed
KSimi7 opened this issue May 29, 2019 · 18 comments
Closed

installation problem #51

KSimi7 opened this issue May 29, 2019 · 18 comments
Assignees
Labels
question Further information is requested

Comments

@KSimi7
Copy link

KSimi7 commented May 29, 2019

I am working on a new project that involves Ecell and hence I am trying to install it. I have tried everything as mentioned in instructions but there is some issue with the installation for ecell4-base. If I type in command pip install ecell4 it says that it could not fulfil the requirement of ecell4-base because it could not find ecell4-base in ecell4 version. I am relatively new to this field so kindly help me. Please. Suggest the changes I can do and also why this issue is happening in first place?

@kozo2
Copy link
Member

kozo2 commented Jun 1, 2019

@Harsimran2019
Could you tell me which OS you use?
I ran pip install ecell4 on Google Colab for a quick check, and the installation was completed successfully.
image

@KSimi7
Copy link
Author

KSimi7 commented Jun 1, 2019

I am using Windows 10 Education version 1803 OS build 17134.765.
I tried pip installing ecell a lot many times but It did not work as it could not find ecell4 base for some reason. I manually installed it using the setup.py in ecell4 zipper file folder and it was installed correctly just to check I again did pip install ecelll4 on jupyter notebook as you can see.

image

but then I tried to run the basic tutorial given on ecell4 read the docs but it did not work.

image

image

@kaizu
Copy link
Member

kaizu commented Jun 1, 2019

@Harsimran2019 I also tried on WIndows 10 with Anaconda3 (64-bit).

Did you install hdf5?
As shown here (https://github.com/ecell/ecell4-base/blob/master/INSTALL.md), you need to install hdf5 separately. Please check if it is installed correctly. Sorry for no explanation in README.md.

> conda list
hdf5                      1.10.4               h7ebc959_0

This is what I did on Anaconda Prompt (not on Jupyter Notebook):

> conda uninstall hdf5
> conda install hdf5
> pip install ecell4

Please remove all ecell4 staffs once, and try again after installing hdf5.

I tried pip installing ecell a lot many times but It did not work as it could not find ecell4 base for some reason.

Did you fail pip install ecell4? Or you mean that it is installed but doesn't work?

@KSimi7
Copy link
Author

KSimi7 commented Jun 1, 2019

Pip install ecell4 does not work I tried in anaconda prompt but it does not. I have installed hdf5 before installing ecell4 but when I do pip installation of ecell4
image

It shows this.

@kozo2
Copy link
Member

kozo2 commented Jun 1, 2019

@Harsimran2019
Could you try the following commands? I think this will solve the installation problem.

conda update python pip
pip uninstall ecell4 ecell4_base
pip install ecell4 --no-cache-dir

And the ImportError should be related to loading hdf5.dll.

@KSimi7
Copy link
Author

KSimi7 commented Jun 1, 2019

It again shows the same error.
image

@kozo2
Copy link
Member

kozo2 commented Jun 1, 2019

@Harsimran2019
Do you use 64-bit version of Windows and conda?
I'm sorry I forgot to check this.
You can check this with these commands

winver
conda info

@KSimi7
Copy link
Author

KSimi7 commented Jun 1, 2019

It is 64 bit version of windows but I installed 32 bit miniconda as suggested on installation instructions website.

@kozo2
Copy link
Member

kozo2 commented Jun 1, 2019

@Harsimran2019
Please install 64bit Miniconda instead.
I'm sorry if there was a point to mislead in Miniconda installation instructions.
I will try to improve the document.

@kozo2
Copy link
Member

kozo2 commented Jun 1, 2019

@Harsimran2019
We are currently working on the moving from PyPi wheel package to Conda package to solve installation problems on Windows and Mac.
If you can use the other environment such as Docker or Google Colab, you may want to use it until we finish the Conda packaging transition.

@KSimi7
Copy link
Author

KSimi7 commented Jun 1, 2019

Are the instructions to use Docker are as given on website?
Meanwhile I am trying with 64 bit miniconda

@kozo2
Copy link
Member

kozo2 commented Jun 1, 2019

@Harsimran2019

Are the instructions to use Docker are as given on website?

No. I will add it soon. Please wait a moment.

@KSimi7
Copy link
Author

KSimi7 commented Jun 1, 2019

I just tried installing it on 64 bit miniconda it got installed correctly but I tried running following commands as given on brief tutorial on ecell4.
The following command shows this error
image

@kozo2
Copy link
Member

kozo2 commented Jun 1, 2019

@Harsimran2019
Sorry, I will update the Python script soon. > Sphere
And now I found a problem in the run_simulation function.
(The Spherical simulation will fail)
Please wait for a while to fix the problem.

@kozo2
Copy link
Member

kozo2 commented Jun 1, 2019

@Harsimran2019
Please replace the script to

from ecell4 import *
from ecell4_base import core

with species_attributes():
    A | {'D': '1', 'location': 'M'}

surface = core.Sphere(core.ones() * 0.5, 0.5).surface()
obs = core.FixedIntervalTrajectoryObserver(1e-4)

@kozo2
Copy link
Member

kozo2 commented Jun 1, 2019

@Harsimran2019
But the following run_simulation will fail like

image

We will fix it, please wait for a while.

@KSimi7
Copy link
Author

KSimi7 commented Jun 1, 2019

Alright. Thank you so much for your help.
I am going to do a project using E-cell4 and I do not have any programmer background as such I just know one language C and I have been trying to learn python. Any other skills or some literature that you could suggest I should review to work with Ecell.

Kindly let me know when this is fixed.
Again thank you so much.

@kaizu
Copy link
Member

kaizu commented Jun 2, 2019

@Harsimran2019
This should work:

from ecell4 import *
from ecell4_base.core import *

with species_attributes():
    A | {'D': 1, 'location': 'M', 'dimension': 2}
    M | {'dimension': 2}

surface = Sphere(ones() * 0.5, 0.4).surface()
obs = FixedIntervalTrajectoryObserver(1e-4)

run_simulation(
    0.4, y0={'A': 10}, structures={'M': surface},
    solver='spatiocyte', observers=obs, return_type=None)

viz.plot_trajectory(obs, interactive=True)

viz.plot_trajectory(obs, interactive=False) doesn't work yet due to a bug. We'll fix it soon (#52).

As @kozo2 explained, we are preparing for the new version. This problem seems caused by the difference between versions.

  1. In addition to import ecell4, users also need to import ecell4_base.core for some classes such as Sphere, FixedIntervalTrajectoryObserver, and ones.
  2. dimension must be given in the model. M, which is a spherical surface, leads two dimensional diffusion on it. Thus, you need to set M | {'dimension': 2}. Without that, simulators regard its dimension as three. We will modify this as it warns when the dimension mismatches.
  3. Please use the smaller radius for Sphere (0.5 -> 0.4) because it is a bit large relative to the size of the World (1.0 for default). I'm not sure why it works before.

I am going to do a project using E-cell4 and I do not have any programmer background as such I just know one language C and I have been trying to learn python. Any other skills or some literature that you could suggest I should review to work with Ecell.

A Python skill is enough to use ecell4.
BTW, what kind of algorithm do you have an interest in? Here (https://doi.org/10.1016/j.febslet.2005.01.072) is a quick review for algorithms. For more details about the Spatiocyte method (one of our particle algorithms), please check this (https://doi.org/10.1007/s11693-009-9047-2).

Slack (https://ecell-project.herokuapp.com/) is also open for questions. Please feel free to ask there.

Thank you for your report!

@KSimi7 KSimi7 closed this as completed Jun 2, 2019
@kaizu kaizu added the question Further information is requested label Jun 3, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants