On Tuesday, August 7, 2012 4:46:45 PM UTC+5:30, Stefan Krastanov wrote:
>
> I was checking the code again recently and now I have a few new 
> questions about the adaptive sampling (this is part of a gsoc project, 
> however the questions are to anybody interested): 
>
>  - currently there is duplication of code in the sampling method for 
> line plots and parametric line plots. Is it going to get better 
> abstracted, or is this a low priority issue for now?


I haven't figured out how to abstract it better. Because they have to be
implemented differently for parametric and line plots 

>  
>  - currently it overrides get_segments and get_points. Won't it be 
> cleaner if it overrides only get_points? Why not? (I think it will be 
> cleaner because the base LineSeries class already implements 
> get_segments based on get_points, and I would really hate to have the 
> logic reimplemented multiple time, as it is now) 
>

Yes. It would be better. But the problem is maintaining the order of those 
points i.e
if you want to insert new points between two points, then you will have to 
create
a new list. Adding to the same list is difficult. Also, the recursion code 
will be more
complex as it should be changed to something iterative rather than 
recursive. 

>  - What is the plan about implementing variable recursion depth? 

 - What is the plan about disabling the adaptive sampling? 
>  - What happens currently to the number_of_points option? 
>
Yes. I am implementing it in the new API. The number_of_points will be used 
when
adaptive is set to false. You can have a look at how the new API is going 
to be at
[1]. 

>  - Is there an issue about implementing this also for 3D line plots
>
Actually not. It will be easy enough. I will try implementing it. 

> (not 3D surface plots which would need triangular meshes)? 
>  - Is there an issue about the much harder problem for 3D plots? 
>
I don't know how to do it with triangular meshes. I will have to read up,
before I try implementing it.

[1] https://github.com/sympy/sympy/pull/1468 

-- 
You received this message because you are subscribed to the Google Groups 
"sympy" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/sympy/-/tEkYbwpPZPoJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sympy?hl=en.

Reply via email to