pyswarms icon indicating copy to clipboard operation
pyswarms copied to clipboard

Revisit and update documentation and examples

Open ljvmiranda921 opened this issue 4 years ago • 8 comments

I think one of the more common issues we encounter is that some examples don't work out of the box. We may have introduced a lot of changes in the API from the previous versions and weren't able to update the docs properly.

Let's scope this one out, right now we have docs located in:

  • Our docstrings
  • Jupyter notebooks

I know we did this exercise before, but it may be good to revisit it again just to be really sure that everything is working well.

Let me know what you think @whzup @stevenbw

ljvmiranda921 avatar Apr 20 '20 15:04 ljvmiranda921

I found some unrendered math here.

whzup avatar Apr 21 '20 17:04 whzup

I also think we should open an issue for a collection of architecture updates we want to make (e.g. see #235, #259).

whzup avatar Apr 21 '20 17:04 whzup

^Agree! Or we can just reuse the existing issues #235 #259 and include them in this current effort. Also @whzup , no pressure here, I appreciate that you're taking the time and holding the fort answering Issues and reviewing PRs, but focus on your thesis and graduation! I'm rooting for you!

ljvmiranda921 avatar Apr 21 '20 21:04 ljvmiranda921

I think one of the more common issues we encounter is that some examples don't work out of the box. We may have introduced a lot of changes in the API from the previous versions and weren't able to update the docs properly.

Let's scope this one out, right now we have docs located in:

  • Our docstrings
  • Jupyter notebooks

I know we did this exercise before, but it may be good to revisit it again just to be really sure that everything is working well.

Let me know what you think @whzup @stevenbw

In case of a n_process>2, an addition consideration must be given to Jupyter Notebook for windows users.

https://stackoverflow.com/questions/47313732/jupyter-notebook-never-finishes-processing-using-multiprocessing-python-3

msat59 avatar May 01 '20 23:05 msat59

More unrendered math https://pyswarms.readthedocs.io/en/latest/api/pyswarms.backend.html#module-pyswarms.backend.handlers

whzup avatar May 04 '20 05:05 whzup

@ljvmiranda921 Do you think it would be a good idea to build a MWE for a custom optimizer in Writing your own optimization loop?

whzup avatar May 05 '20 12:05 whzup

^Ooooh, you meant like a scaffold of it? @whzup yeah that would be good to be honest. I think just describing what it looks like (what I did) isn't enough

ljvmiranda921 avatar May 05 '20 16:05 ljvmiranda921

Hello,

I am currently like to work with pyswarms and had a look in your Documentation. In your example Electric circuit problem is an false result in your section Setting the optimizer.

The results are:

[5]: print(pos[0])
0.23426529444241187

[6]: print(cost)
14.045352861989468

But later you talk about 0.094A, which I can confirm when running the code local in my notebook. This made me a little bit confiused when reading the docs.

if it is desired I can create a pull request with the correction.

svhoy avatar Feb 17 '24 15:02 svhoy